Ferrari's Formula One world championship leader Sebastian Vettel has held on to win a nail-biting Bahrain Grand Prix in the German's 200th race start.
The win was the 49th of the four-time champion's career.
Daniel Ricciardo was forced to retire early while Finland's Valtteri Bottas finished second for Mercedes, a mere 0.699 seconds behind after chasing down Vettel over the closing laps.
"You're up all day waiting for those two hours and after two minutes it's over," Ricciardo said.
Teammate and reigning champion Lewis Hamilton was third.
"These tyres were done, done, in the last 10 laps," a jubilant Vettel told his team over the radio after he took the chequered flag.
He had earlier told his team that everything was under control but that, he recognised later with a smile, was not the reality.
"With Bottas' pace I thought he would catch me. I tried to keep it as clean as possible. Our plan worked but just, Bottas had a bit of a sniff but ran out of laps," he said.
Vettel had led from pole position, with Bottas slotting into second place at the start from third on the grid, but ended up having to battle the Mercedes pair alone.
A disastrous pit stop for team mate Kimi Raikkonen left a Ferrari mechanic injured on the ground and forced the Finn's retirement. It was later announced the mechanic had suffered a broken leg.
"I am a bit sad, because in the pit stop with Kimi one of our mechanics got injured," Vettel said. "I send him the best regards, and I'm sure the guys are looking after him."
Hamilton meanwhile came from ninth, after a five-place grid penalty, to secure a record-equalling 27th successive points finish.
"I started ninth so third is not bad at all," said the Briton. "It's damage limitation."
Both of the Red Bull drivers Max Verstappen and Ricciardo retired, but the energy drink company's other team Toro Rosso celebrated a remarkable day with fourth place for French driver Pierre Gasly.
That represented a best result of the V6 turbo hybrid era for Honda, Toro Rosso's engine partners after three nightmare years at McLaren.
There were also celebrations at Sauber, with Sweden's Marcus Ericsson finishing ninth for his first points since 2015 and the Swiss team's first of the season.