Lewis Hamilton's late charge was not enough to stop Sebastian Vettel from winning the Bahrain Grand Prix and taking overall lead of the championship.
A masterclass from Vettel on track, and the right strategy calls from his Ferrari team off it, enabled the four-time champion seal his second win of the campaign and take an early advantage over Hamilton in the title race.
Pole-sitter Valtteri Bottas finished in third position, with Kimi Raikkonen crossing the line in fourth.
Bottas, the first Finn to start from pole in nearly a decade, blasted out of the blocks to retain his lead on the long run down to turn one.
It was a steady start from Hamilton, but Vettel showed greater bravery on the brakes and passed his championship rival round the outside to move into second place.
For the second grand prix in succession, the fearless Max Verstappen was on the move on lap one after he passed Raikkonen and then Red Bull team-mate Daniel Ricciardo to take fourth.
While Bottas led he was not pulling away from the chasing pack. Indeed the top five were covered by just three seconds.
And it was Vettel who was the first of the leaders to blink as he stopped at the end of lap 10 to take on the supersoft tyre, the quicker but less durable of the three compounds available here.
Surprisingly Mercedes did not bring in either Bottas or Hamilton to cover off Ferrari's strategy, but Red Bull did with Verstappen. In came the Dutchman, but he was out of the race only moments later after a brakes failure saw him end up in the wall at turn four.
Lance Stroll, the 18-year-old Canadian rookie whose career has been bankrolled by his fashion billionaire father Lawrence, has endured a tricky start to life in Formula One, and he was in the wars again on Sunday after he crashed into the Toro Rosso of Carlos Sainz as the Spaniard left the pits.
Stroll's car was in a dangerous position at the exit of turn one and the safety car was dispatched. In came Bottas and Hamilton, too, but fearing he would lose time queuing behind his Mercedes team-mate, Hamilton slowed down on his approach to the Mercedes garage and effectively blocked Ricciardo.
A slow stop ensued for Hamilton - some six seconds - as his team struggled to get on the front-left tyre and the Briton emerged behind Ricciardo. To make matters worse he was then slapped with a five-second timed penalty for driving too slowly into the pits. In a matter of laps, the race had swung firmly in Vettel's favour.
The safety car came in at the end of lap 16 and Hamilton - eager to make amends - was on the move straightaway as he nailed Ricciardo at turn one.
Running in third, Hamilton then urged his Mercedes team to let him past Bottas with Vettel sailing off into the distance. Mercedes played ball asking the Finn to allow Hamilton through only to change their mind one lap later. But on lap 26, and with Vettel now six seconds up the road, the telephone call came from the pit wall to instruct Bottas to get out of Hamilton's way.
The former Williams driver duly obliged with Hamilton now in pursuit of Vettel and his lead.
Vettel stopped on lap 33 for his second change of rubber to allow Hamilton to take the lead of the race. Could Hamilton get to the end on his soft tyres? The answer arrived eight laps later as he stopped for a second time. He took on his penalty, too, to leave him back in third.
But on new rubber Hamilton, 10 seconds down on Bottas, began his fightback. Within just six laps he had caught and overtaken Bottas - diving underneath his team-mate at the final corner.
"You've got the pace to win this," said Hamilton's race engineer Pete Bonnington. Surely, Hamilton could not do the unthinkable with Vettel nearly 14 seconds ahead?
And despite getting the gap down to 6.6 seconds, Hamilton fell short with the Ferrari driver moving seven points clear in the championship.
McLaren endured a desperately disappointing day with Stoffel Vandoorne failing to start and Fernando Alonso, who expressed his anger at his sluggish Honda engine throughout the race, retired in the closing stages.
Briton's Jolyon Palmer started a career-high 10th but was 13th and last of those who finished.
F1 DRIVERS TABLE | 2017
|5||Max Verstappen||Red Bull||25|
|6||Daniel Ricciardo||Red Bull||22|
|8||Sergio Perez||Force India||14|
|9||Carlos Sainz Jnr||Toro Rosso||10|
|10||Romain Grosjean||Haas F1||4|
|11||Kevin Magnussen||Haas F1||4|
|12||Esteban Ocon||Force India||3|
|14||Daniil Kvyat||Toro Rosso||2|