Lewis Hamilton took victory in a sensational Formula 1 German Grand Prix while his title rival Sebastian Vettel crashed out as a rain storm struck the Hockenheim circuit.

Vettel had led for the majority of the race from pole position, but slithered out of contention from the lead, on lap 52 of the 67 race. The German hit his steering wheel in frustration at the mistake of crashing into the Turn 13 barriers.

Hamilton started 14th and took advantage of the downpour that soaked the circuit in the latter stages that caught out a number of slick-shod drivers – including Vettel – and which led to the safety car to be deployed.

In the chaos, there was an instant reversal of fortune as a Ferrari 1-2 became a Mercedes 1-2 during the rain shower.

All race, teams were constantly trying to second guess the conditions and most drivers stayed out on dry-weather tyres while the storm passed and the circuit began to quickly dry up.

Valtteri Bottas finished in second, but had an attempt at overtaking his teammate when the safety car period ended on lap 57.

The Finn got alongside Hamilton at the Turn 6 hairpin, but Hamilton was just able to retain the lead. Just a lap later, Bottas was instructed to hold position.

Kimi Raikkonen took third place, ahead of Max Verstappen's Red Bull. The Dutchman had been one of the drivers to gamble on wet tyres when the rain started to fall in just one section of the track.

Two laps later, Verstappen had returned back to the pits for dry tyres – the gamble failed – but then the whole circuit was doused, leading to the Safety Car's deployment.

Nico Hulkenberg was fifth for Renault, ahead of Romain Grosjean's Haas and the two Force Indias. Sauber's Marcus Ericsson and Brendon Hartley both benefitted from the chaotic conditions to scoop the final point-finishing positions.

At the start, Vettel led away from Bottas, Raikkonen and Verstappen and was comfortably in control of his home race. By lap 25, Vettel held a five-second lead over Bottas when he came in to pit from ultra tyres to softs.

His Ferrari teammate Raikkonen was the first of the frontrunners to pit on lap 14 and once the first stops were over, the Finn held a slim lead over Vettel.

But the German was on tyres that were 11 laps fresher and Raikkonen was instructed by engineering director Jock Clear to led Vettel past.

Hamilton started on the soft tyre and made swift progress in the early laps to make his way through the field.

After starting 14th, he was up to seventh by lap eight. It was a remarkable comeback drive that has significant implications in the championship battle, as Hamilton retakes the number one spot.

Cla Driver Chassis Engine Time
1 united_kingdom Lewis Hamilton  Mercedes Mercedes  
2 finland Valtteri Bottas  Mercedes Mercedes 4.535
3 finland Kimi Raikkonen  Ferrari Ferrari 6.732
4 netherlands Max Verstappen  Red Bull TAG 7.654
5 germany Nico Hulkenberg  Renault Renault 26.609
6 france Romain Grosjean  Haas Ferrari 28.871
7 mexico Sergio Perez  Force India Mercedes 30.556
8 france Esteban Ocon  Force India Mercedes 31.750
9 sweden Marcus Ericsson  Sauber Ferrari 32.362
10 new_zealand Brendon Hartley  Toro Rosso Honda 34.197
11 denmark Kevin Magnussen  Haas Ferrari 34.919
12 spain Carlos Sainz  Renault Renault 43.069
13 belgium Stoffel Vandoorne  McLaren Renault 46.617
14 france Pierre Gasly  Toro Rosso Honda 1 lap
15 monaco Charles Leclerc  Sauber Ferrari 1 lap
16 spain Fernando Alonso  McLaren Renault 1 lap
17 canada Lance Stroll  Williams Mercedes 14 laps
18 germany Sebastian Vettel  Ferrari Ferrari 16 laps
19 russia Sergey Sirotkin  Williams Mercedes 16 laps
20 australia Daniel Ricciardo  Red Bull TAG 40 laps

Gallery: German GP: Hamilton wins from 14th as Vettel crashes out