Valtteri Bottas will start the 2019 Azerbaijan Formula One Grand Prix from pole position on Sunday after beating Mercedes team-mate Lewis Hamilton to top spot in a dramatic qualifying session.
Ferrari's Sebastian Vettel took third place behind the two Silver Arrows, but team-mate Charles Leclerc will start down in 10th place after crashing in Q2.
Red Bull Racing's Max Verstappen will start alongside Vettel in fourth, while Racing Point's Sergio Perez will start from an impressive fifth place on the grid.
Here are the results from qualifying:
Ferrari dominated the practice sessions and did the same early during the first qualifying session, as Leclerc became the first driver to duck underneath the one-minute, 42-second mark.
Mercedes took some time finding their footing but eventually improved, bridging the gap there had been during practice.
Red Bull also found some pace late in the session, with Pierre Gasly knocking the Monegasque out of the top spot.
The Frenchman knew his eventual finishing position in qualifying wouldn't mean much, as he'll start from the pit lane:
Renault struggled in FP2 and didn't have a great outing in FP3, either, and their start to qualifying was hardly ideal.
Minutes into the first session, Daniel Ricciardo was told the team had no data, leaving him without crucial info on a busy track:
The Australian eventually worked himself out of the drop zone after a difficult session, shortly before Williams' Robert Kubica shunted, bringing out the red flag. Nico Hulkenberg and Romain Grosjean were among the drivers to miss out on Q2.
The shunt was a big one:
Drivers were forced to wait while the track was cleared, adding an extra element of strategy. As the temperature dropped, Ferrari took a risk by opting for medium tyres, while everyone else ventured out on the soft compound.
Leclerc's first time was reasonably close to that of the Silver Arrows, but Vettel was well off the pace. Once Perez went faster than the younger Ferrari driver, it became clear the Scuderia had made a tactical error.
But things got much worse for the team shortly after. Leclerc, who had been the fastest man on track for most of the weekend, hit the wall in the same spot Kubica did, ending his session.
The 21-year-old was furious with himself:
The crash brought out another red flag and another delay. Liquid coming from the car made things more difficult for the marshals, and the lengthy break meant the end of the session would take place in the fading light.
The session eventually restarted with Carlos Sainz, Ricciardo, Alexander Albon, Kevin Magnussen and Gasly all missing out on Q3.
Ricciardo will start down in 12th place in the Renault:
The final session saw Verstappen, Hamilton, Bottas and Vettel all vying for pole position in a dramatic finish. Bottas was the man to come up with the goods, setting a new track record of 1:40.495 to secure top spot ahead of Hamilton and secure an all Mercedes front row.