Carlos Sainz fended off Mercedes' charge to win a pulsating Singapore Grand Prix after clinging on despite last-gasp pressure and capping off a controlled drive.
Having led most of the race comfortably after charging away at lights out and being shielded by wingman Charles Leclerc, Sainz was suddenly reeled in over the final laps by the marauding George Russell and Lewis Hamilton.
Indeed, Mercedes had gambled under a late Virtual Safety Car by strapping on fresh tyres for both drivers and they made light work in closing the gap on the squabble at the front of the grid, setting up a grandstand finish under the lights.
But neither Russell nor Hamilton were able to get the better of Lando Norris, who defended valiantly. Russell then crashed out of third place on the last lap.
Sainz subsequently took the chequered flag first in breathtaking fashion, quickly followed by Norris and Hamilton. Leclerc was ultimately made to settle for fourth.
The triumph was Ferrari's long-awaited first since July 2022 and ensured the first non-Red Bull race winner since the penultimate race in Brazil last season.
Despite Red Bull's record-breaking winning run stuttering to a halt, Max Verstappen shook off a mixed weekend to finish fifth after a superb fightback.
Pierre Gasly, Oscar Piastri, Sergio Perez, Liam Lawson and Kevin Magnussen rounded off the rest of the top 10, meanwhile, after a race that ebbed and flowed.
It took just seconds for the two Mercedes drivers to lock horns, with Hamilton diving down the run-off after fighting wheel-to-wheel with Russell.
Hamilton was able to move ahead at the first corner, though, having surrendered the apex, leaving Russell asking whether he would be handed the place back.
Shortly after, they did indeed swap positions, though Norris also demanded to be let through, suggesting Hamilton carried more speed due to cutting the corner.
Again, Hamilton made way, albeit after claiming he was pushed wide by Russell.
Yuki Tsunoda was an early retirement after stopping at the start of the final sector at Turn 14 and insisting he had picked up a puncture after a tussle with Perez.
Bunched up battle
Despite his seamless start, Sainz was unable to disappear over the horizon.
Behind, Russell, Hamilton and Norris all found themselves within DRS range of each other, while Leclerc benefitted from his strong pace on his softs in second.
Indeed, Ferrari had laid down the early gauntlet and both drivers built up a healthy gap. Leclerc, though, was soon warned to pull further behind Sainz.
Intriguingly, Russell was informed over team radio that Ferrari were likely to sacrifice Leclerc in a bid to protect Sainz and increase their advantage.
Further down the points, Verstappen belatedly passed Magnussen toward Turn 14 and set his sights on the Alpine of Ocon, a podium finish in his sights.
Safety Car drama
As is tradition in Singapore, it was simply a matter of time before the Safety Car was deployed. This time, Sargeant's clumsy crash at Turn Eight sparked havoc.
Despite limping back to the pits with his battered front wing tucked under his wheel, debris was scattered on the track following his collision with the wall.
Every driver aside from Verstappen and Perez dived into the pit lane, with Ferrari opting to rapidly double stack the race leader Sainz and then Leclerc.
The latter emerged worse off, however, after being held up by the crew. He subsequently tumbled behind Russell and Norris, a costly mishap.
Having locked up and crossed the white line on his way into the pit, Alonso, running in eighth, was hit with a slam-dunk five-second penalty.
Game on!
With the pack shaken up, Sainz's superb restart saw him pull away from Verstappen, who had missed out on bolting on fresh rubber.
Russell then dived down the inside of Verstappen into Turn 16 and took second, with Norris outmanoeuvred Perez and moved into fourth shortly after.
Norris, dancing along on his new tyres, then passed Verstappen, who was promptly outmatched by Hamilton and continued to slump down the order.
"It's like driving on ice," Verstappen complained over team radio.
With the top five enthrallingly sandwiched together, Russell voiced his confidence his tyres would last the distance due to Sainz's cautious approach in front.
Mercedes' Hail Mary
Heavily reliant on another Safety Car, Red Bull brought an end to Perez and Verstappen's pain after belatedly hauling them in for new tyres.
The two struggling drivers re-emerged in 18th and 15th respectively, leaving the world champions facing the possibility of not scoring any points.
Shortly after, however, Esteban Ocon ground to a halt at Turn Two after losing drive, opening the door for Mercedes to pull off a double stack.
Rolling the dice in late drama, Russell and Hamilton pitted under a Virtual Safety Car and strapped on new mediums to mount a charge on the top three.
Ultimately, the gamble proved a tactical masterstroke but fell agonisingly short.