Lewis Hamilton will start on pole position at the Spanish Grand Prix for the third time in four years after edging out drivers' championship rival Sebastian Vettel in Barcelona.
The Mercedes driver started from pole position but immediately lost out to Ferrari's Vettel at the first corner as the German got a great start from second on the grid.
However, he was unable to improve on his second run, and that nearly let Ferrari in, although in the end Vettel crossed the line and was 0.051secs down - and 0.173secs up on Bottas. The third row, as has been the case recently, is occupied by the two Red Bull cars of Max Verstappen and Daniel Ricciardo. "Then, maybe you should ask the Italians; they seem to know more than I do".
"I felt like I ran out of road and I was on the outside but that is racing and I wouldn't have changed it for the world", Hamilton added.
"I think it is going to be a tough race for us, when you see how close it is between us - it is milliseconds", Hamilton said.
But an inspired strategic call from Hamilton's Mercedes team won him the race.
"A big thank you to the team, because we had to change the engine last minute and the auto was just about finished, so today is really for the mechanics - also from Kimi's vehicle that helped out, grazie", he said.
However, Bottas performed well in the first two practice sessions, clocking the second-fastest times behind Hamilton in both.
Ferrari driver Kimi Raikkonen of Finland steers his auto during the third practice session for the Spanish Formula One Grand Prix at the Barcelona Catalunya racetrack in Montmelo, Spain, Saturday, May 13, 2017.
Q1 started with a scare for Vettel as the German was told by Ferrari to stop his auto on track.
The four times world champion hesitated to obey the instruction, however.
Hamilton vs Vettel: Finally we saw these two legends of the sport go wheel-to-wheel.
"I felt yesterday we had it in the auto. In terms of performance, it will be really close".
Felipe Massa collided with both McLaren cars. "It would have been nice to get them pole but hopefully a good race tomorrow".
Mexican Sergio Perez finished fourth, his 15th successive points finish, for Force India with French rookie team mate Esteban Ocon fifth. Carlos Sainz took seventh in his home race for Toro Rosso, while Sauber celebrated their first points of 2017 thanks to Pascal Wehrlein's eighth place. By comparison Bottas locked up and ran wide in turn 1 on his first flying lap, and was forced to run a put more wear on his race tyres to put in a lap just under a tenth off his team mate.