Jenson Button won a chaotic Canadian Grand Prix that finished over four hours after it started, and which included a red flag and five safety car periods, despite a penalty and two accidents.
The Briton, however, is under investigation for clashes with Lewis Hamilton and Fernando Alonso.
Button's victory came only after Sebastian Vettel lost the lead on the final lap due to a driving error with just a handful of corners left.
The world champion had dominated the race from the start but came under pressure from a flying Button in the end.
Mark Webber was third for Red Bull, with Michael Schumacher in fourth position and Renault's Vitaly Petrov completing the top five.
Felipe Massa was the only Ferrari driver to finish, in sixth place, after beating Kamui Kobayashi to the spot right on the finish line.
Jaime Alguersuari, Rubens Barrichello and Sebastien Buemi completed the points-paying positions.
The event started under the safety car, as the race director deemed the track was too wet for a standing start. The move meant all drivers had to start will full wet tyres. The DRS was disabled while the track was wet.
The safety car dived into the pits after five laps, and Vettel managed to keep the lead despite an attack from Ferrari's Fernando Alonso.
Vettel's team-mate Webber was not so lucky, however, and spun after making contact with the McLaren of Lewis Hamilton, the Australian dropping down to 14th position. Hamilton lost a few places too, and then dropped behind Button after going wide at the hairpin when fighting with Schumacher.
The Briton tried to regain the position on lap seven, only to make contact with Button as he tried to pass on the main straight. Hamilton had been quicker coming out of the final corner and tried to pass his team-mate on the left, only for Button to close the door.
Their cars made contact and Hamilton hit the wall, retiring from the race a few corners later and forcing the deployment of the safety car after parking his damaged car after Turn 5. Button pitted for repairs and rejoined in 12th place.
The race was relaunched again on lap 12, with Vettel still leading from Alonso and Massa. Right after that, race control announced a drive-through penalty for Button for having sped under the safety car. The Briton, who had opted for intermediate tyres in his first stop, dropped down to 14th.
Up front, Vettel stretched his lead quite comfortably, but Alonso decided to pit for intermediates on lap 18, seeing that Button was the fastest man on track.
Alonso rejoined in eighth, right in front of Vitaly Petrov and Button himself, but the rain became a downpour moments later and the safety car was deployed for the third time, with Alonso deciding to pit again for full wets.
Leader Vettel and team-mate Webber pitted for full wets during the safety car period, the Australian also getting a new steering wheel as he was having problems shifting down gears. Several drivers followed suit into the pits, leaving Vettel in the lead again, ahead of Sauber's Kamui Kobayashi, who had not stopped, and Massa.
Still under the safety car, Vettel told his team on the radio that it was impossible to drive and that the race should be stopped. On lap 25, Vettel's wish was granted, and the race was red-flagged.
Nearly two hours after it was stopped, the race was restarted behind the safety car and with mandatory full wet weather tyres.
Heikki Kovalainen became the second retirement even before the safety car was back in, the Finn suffering a driveshaft failure on lap 30.
After nine laps on track, the safety car drove into pits and the race was launched with Vettel on top, followed by Kobayashi, who managed to keep Massa at bay at the first corner.
The majority of the field pitted as soon as it was allowed to fit intermediates tyre, although Vettel stayed out for a couple of laps, before the safety car was deployed again when Button made contact with Alonso when trying to pass at Turn 3.
The Briton touched the Ferrari's right rear wheel and sent the Spaniard into a spin, his car getting stuck on the kerbs. Button had to pit to change his punctured tyre.
At the time of the fourth safety car of the day, Vettel led from Kobayashi, Massa, Heidfeld, Paul di Resta and Webber, with Button dropping down to the bottom of the field.
The race resumed on lap 41, with Vettel opening a clear gap right away as Kobayashi held a train of cars behind him.
There was a lot action behind the German, with several position changes which included a clash between Heidfeld and di Resta, the Scot having to pit for a new front wing. Heidfeld's team-mate Petrov was given a drive-through penalty moments later for having overtaken while the safety car was still on track.
Despite the track being still wet, the race director enabled the use of the DRS on lap 45.
By lap 50 - with 20 to go - Vettel was leading Kobayashi by over six seconds and Massa by seven, with Schumacher having charged to fourth.
On lap 51, Webber became the first of the lead drivers to change to slick tyres, as Schumacher passed both Massa and Kobayashi and set his sights on Vettel, both still on intermediates.
However, the Red Bull driver was still the quickest man on track, extending his lead over Schumacher to 11 seconds by lap 52. Schumacher pitted for slicks a lap later, with Massa following suit.
Vettel changed his tyres a lap later, as team-mate Webber showed slicks were the way to go, lapping three seconds faster than the German. The world champion rejoined the race in the lead, while Massa was forced to come into the pits after damaging his front wing when losing control of his car while lapping an HRT.
With 13 laps to go, the safety car was deployed for the fifth time when Heidfeld crashed out following contact with Kobayashi. The Renault driver had damaged his front wing in the clash, and then it got under his car at speed, sending him off the track, and leading to the safety car being deployed while the wing debris was cleared.
With nine laps to go, the race was relaunched once more with Vettel on top, followed by Schumacher, Webber, Button and Kobayashi. Vettel continued his flawless run, opening a gap quickly as Webber and Button pushed a slower Schumacher hard.
Webber passed Schumacher with six laps to go, but had to let German through as he had jumped the final chicane. On the following lap he made the same mistake again, this time losing third place to Button. The Briton took second with five laps left, passing Schumacher comfortably and launching his attack on Vettel.
Webber finally captured third place from Schumacher with three laps left as Button closed in on Vettel. The world champion, however, resisted the pressure until the final lap, when he lost control of his car and let Button through with just a few corners left.