Taking over from new Mercedes team-mate Valtteri Bottas for the afternoon session, Hamilton completed 73 laps of the Circuit de Barcelona-Catalunya with the quickest time, a 1:21.765, 0.113 clear of Vettel's best efforts.
Felipe Massa was third quickest for Williams, as the top three teams all completed over 100 laps of running, something that baffled Toro Rosso's Carlos Sainz, whose day was marred with a few niggling issues.
In the morning session, Vettel posted the quickest time.
McLaren and Red Bull strike trouble
On the McLaren, it was an oil sensor issue that required Honda taking most of the day to fix, although the Spanish driver was able to complete 29 laps in total once the issue was fixed in the afternoon.
Ricciardo was hit with sensor trouble on his RB13, although played down the incidents after completing 50 laps, saying that the Renault engineers were just playing safe and that there was no real cause for concern.
Headline times are not important in pre-season testing, let alone the first day of the first test as teams focus on getting to grips with their new cars, more crucial than ever with the new breed of cars for '17.
The majority of the field stuck to running with the Soft or Medium compound tyres.
History for Magnussen
Driving out of the pits for the first time as a Haas driver, Kevin Magnussen became the first driver to sample all of the Power Units.
Having raced for McLaren-Mercedes in 2014, driven for McLaren-Honda in 2015 and then with Renault last year, the Haas-Ferrari was Magnussen fourth different engine in just four years.
He was quick enough to put the VF17 in fourth place, just pipping Ricciardo on his late glory run.
Sergio Perez was busy in the morning, although an exhaust problem on his Force India VJM10 forced his running to be limited to just the 39 laps.
Nico Hulkenberg, in his Renault was the first driver to hit the track in the morning session, completing 57 laps on his way to ninth, whilst Sauber's Marcus Ericsson brought up the rear, just over five seconds slower than the fastest time from Hamilton.
|1.||Lewis Hamilton||Mercedes||1:21.765||N/A||Soft||73 (Team Total 152)|
|5.||Daniel Ricciardo||Red Bull||1:22.926||+1.161||Soft||50|
|6.||Valtteri Bottas||Mercedes||1:23.169||+1.404||Soft||79 (Team Total 152)|
|7.||Sergio Perez||Force India||1:23.709||+1.944||Soft||39|
|8.||Carlos Sainz Jr||Toro Rosso||1:24.494||+2.729||Medium||51|