Felipe Massa was well on his way to a surprise victory in the Hungarian Grand Prix when, three laps from home, his Ferrari gave up the ghost and handed a maiden Formula One triumph to Heikki Kovalainen.

Massa was five seconds ahead of pre-race favourite Lewis Hamilton when the Briton suffered a puncture that scuppered any hopes of a fightback from the McLaren man in the second half of the race. The Brazilian had made a storming start and braved it out with the world championship leader through the first two corners and a lights-to-flag victory appeared on the cards until the Ferrari coasted to a halt in full view of the pit-lane.

Hamilton's hopes of a third straight win disappeared when, having failed to jump Massa at the first round of pit-stops, he suffered a left front puncture that not only left him outside the top ten, but also meant that he had to run the final 28 laps on the super-soft Bridgestone tyre. The Briton seemed to have salvaged three points for sixth place before Massa's exit promoted him a further place.

Kovalainen looked set to salvage a podium for McLaren, but was running well behind Massa when the race fell into his lap. It was a first win for the likeable Finn, in his 28th start.

An unlikely podium was completed by Timo Glock and Kimi Raikkonen, after the German fended off a belated charge from an otherwise lacklustre Finn, who had spent the early stages under Fernando Alonso's rear wing and then struggled with a wayward F2008 in the closing laps.

Alonso, having lost out to Raikkonen at the pit-stops, came home fourth, ahead of Hamilton, Nelson Piquet Jr, Jarno Trulli and Robert Kubica.

Full report and result to follow....