McLaren's Lewis Hamilton roared into the record books as Formula One's youngest champion when he snatched the title in last lap drama at the Brazilian Grand Prix.

The 23-year-old, needing only a fifth place finish in the season-ending race to become Britain's first champion since Damon Hill in 1996, was seconds from failure for the second year in a row as Ferrari rival Felipe Massa swept to victory.

Hamilton entered the last lap in sixth place after a late shower forced a change to wet weather tyres and saw Sebastian Vettel's Ferrari-powered Toro Rosso overtake the McLaren.

With the title disappearing as fast as Massa's Ferrari approached the chequered flag, Hamilton had Toyota's Timo Glock to thank after the German stayed out on dry tyres and was unable to hold on to his fifth place.

Hamilton powered past as the final corner approached.

'Amazing, I can't even get my breath back,' said the astonished Briton, who embraced his father and brother before being mobbed by the team.

Massa, Hamilton's sole title rival, won his home race for the second time in three years to chalk up a record 16th constructors' title for the Italian team.

Hamilton, who missed out by a single point to Ferrari's Kimi Raikkonen in Brazil last season, ended the 18-race season one point clear of Massa.

'He scored more points than me, he deserves to win the title,' said the disappointed race winner. 'I know how to win, I know how to lose.

'This is another day of my life that I'm going to learn a lot from.'

At 23 years and 301 days old, Hamilton broke the age record set by former McLaren team mate Fernando Alonso, the Spaniard who won the first of his two titles with Renault in Brazil at the age of 24, one month and 27 days.

Hamilton's title was the first for Mercedes-powered McLaren since Finland's Mika Hakkinen in 1999.

Massa, the first driver since Alain Prost in 1989 to miss out on the title after winning more races than anyone else, led from pole position after a start delayed for 10 minutes by a sudden downpour while the cars were waiting on the grid.

The safety car was then deployed for two laps after a collision that sent Britain's David Coulthard crashing into retirement after 15 seasons in Formula One.

The Scot's Red Bull tangled with the Williams of Kazuki Nakajima and Renault's Nelson Piquet, who was also eliminated from the race.

Alonso took second place in the race, with Raikkonen joining him on the podium to seize third place overall from BMW-Sauber's Robert Kubica on race wins.

1 F Massa (Bra) Ferrari - 1:34:11.235
2 F Alonso (Spa) Renault - 1:34:24.533
3 K Raikkonen (Fin) Ferrari - 1:34:27.470
4 S Vettel (Ger) Toro Rosso - 1:34:49.246
5 L Hamilton (Gbr) McLaren - 1:34:50.135
6 T Glock (Ger) Toyota - 1:34:55.535

1 L Hamilton (Gbr) McLaren - 98pts
2 F Massa (Bra) Ferrari - 97
3 K Raikkonen (Fin) Ferrari - 75
4 R Kubica (Pol) BMW Sauber - 75
5 F Alonso (Spa) Renault - 61
6 N Heidfeld (Ger) BMW Sauber - 60

1 Ferrari - 172pts
2 McLaren - 151
3 BMW Sauber - 135