The Briton posted a best 1 minute 17.233 seconds around the 4.381-kilometre Hungaroring, a circuit where he has won a record six times. Photo: Laszlo Balogh/AP Photo

BUDAPEST  World champion Lewis Hamilton did just enough to nudge his Mercedes ahead of Max Verstappen's Red Bull in practice for the Formula One Hungarian Grand Prix on Friday.

The Briton posted a best 1 minute 17.233 seconds around the 4.381-kilometre Hungaroring, a circuit where he has won a record six times, in the first session of the day.

But Verstappen was only 0.165 seconds adrift and Sebastian Vettel of Ferrari just 1 thousandth of a second further behind in third.

Verstappen won a wet German GP last weekend and Vettel moved from the back of the grid to second as Hamilton and Mercedes had a rare off day.

And rain again played a big role as showers made teams cautious early in the second session before heavier rainfall saw the clock tick away with little change on the timesheets

Pierre Gasly of Red Bull topped second practice in a modest 1:17.854 minutes with Verstappen next at 0.055 seconds and Hamilton at 0.141 seconds in third.

Hamilton still leads the standings by a comfortable 41 points from team-mate Valtteri Bottas, who did not set a time in the first session due to engine problems but did emerge later on.

Charles Leclerc had to settle for sixth in the other Ferrari behind Gasly and Kevin Magnussen of Haas.

Qualifying is on Saturday for Sunday's race, the last before the mid-season break.

dpa