Ferrari's Felipe Massa claimed pole position for Sunday's European Grand Prix after a thrilling qualifying session in Valencia on Saturday afternoon.
The Brazilian clocked one minute 38.989 seconds to take the top grid position from McLaren's championship leader Lewis Hamilton by 0.210secs as Valencia's street circuit made its debut on the Formula One calendar.
BMW'S Robert Kubica was third, ahead of Ferrari's Kimi Raikkonen.
But there was disappointment for the home crowd as Renault's Fernando Alonso was 12th - his worst placing of the season.
McLaren's Heikki Kovalainen, who won the last Grand Prix in Hungary, will share the third row alongside Toro Rosso's Sebastien Vettel.
Jarno Trulli for Toyota, BMW Sauber's Nick Heidfeld, Williams driver Nico Rosberg and Sebastien Bourdais in the second Toro Rosso rounded out the top 10.
"To take pole for the first time here is very nice," said 27-year-old Massa.
"The surface is a little bit slippery and to make the perfect lap is very difficult. A big, big shower yesterday didn't help the grip.
"But it's a nice track and let's hope we can have a good race, we will do our best."
Grid positions for the European Grand Prix:
1. Felipe Massa (Brz) Ferrari 1 min 38.989 secs
2. Lewis Hamilton (GB) McLaren-Mercedes 1:39.199
3. Robert Kubica (Pol) BMW Sauber 1:39.392
4. Kimi Raikkonen (Finn) Ferrari 1:39.488
5. Heikki Kovalainen (Finn) McLaren-Mercedes 1:39.937
6. Sebastian Vettel (Ger) Toro Rosso-Ferrari 1:40.142
7. Jarno Trulli (Ita) Toyota 1:40.309
8. Nick Heidfeld (Ger) BMW Sauber 1:40.631
9. Nico Rosberg (Ger) Williams-Toyota 1:40.721
10. Sebastien Bourdais (Fra) Toro Rosso-Ferrari 1:40.750
11. Kazuki Nakajima (Jpn) Williams-Toyota 1:38.428
12. Fernando Alonso (Spa) Renault 1:38.435
13. Timo Glock (Ger) Toyota 1:38.499
14. Mark Webber (Aus) RedBull-Renault 1:38.515
15. Nelson Piquet (Brz) Renault 1:38.744
16. Jenson Button (GB) Honda 1:38.880
17. David Coulthard (GB) Red Bull-Renault 1:39.235
18. Giancarlo Fisichella (Ita) Force India-Ferrari 1:39.268
19. Rubens Barrichello (Brz) Honda 1:39.811
20. Adrian Sutil (Ger) Force India-Ferrari 1:39.943