Moto2 champion Toni Elias grabbed pole position for the season finale at Valencia - only the third time in his title-winning year that he will start from the top spot.
The seven-time race-winner, who will be back in MotoGP with LCR Honda next year, was having a low-key session and looked set for an outside front row spot at best.
But then Elias (Gresini Moriwaki) blasted to the front with a 1m36.141s, deposing long-time provisional polesitter Stefan Bradl's Kiefer Suter. The Estoril winner lost another place to Andrea Iannone moments later, before fighting back to pip the Speed-Up rider by 0.008 seconds.
Scott Redding completed the front row for the Marc VDS team, the Briton frustrated by traffic at the end.
Iannone's bid to take second in the championship will be helped by his front-row start, as his rival Julian Simon - who has a six-point advantage - was only seventh. The Aspar rider lost some of his session to electronic problems before salvaging a spot on row two.
Alex de Angelis (JiR Motobi) took fifth ahead of Estoril star Kenan Sofuoglu (Technomag-CIP Suter), with Carmelo Morales (Team Germany Suter) behind Simon in eighth.
Pos Rider Bike Time Gap
1. Toni Elias Moriwaki 1m36.141s
2. Stefan Bradl Suter 1m36.247s + 0.106s
3. Andrea Iannone Speed Up 1m36.255s + 0.114s
4. Scott Redding Suter 1m36.343s + 0.202s
5. Alex De Angelis Motobi 1m36.413s + 0.272s
6. Kenan Sofuoglu Suter 1m36.443s + 0.302s
7. Julian Simon Suter 1m36.515s + 0.374s
8. Carmelo Morales Suter 1m36.572s + 0.431s
9. Karel Abraham FTR 1m36.624s + 0.483s
10. Thomas Luthi Moriwaki 1m36.821s + 0.680s
11. Jules Cluzel Suter 1m36.875s + 0.734s
12. Gabor Talmacsi Speed Up 1m36.885s + 0.744s
13. Kenny Noyes Promoharris 1m36.905s + 0.764s
14. Roman Ramos MIR 1m36.956s + 0.815s
15. Javier Fores AJR 1m36.993s + 0.852s
16. Hector Faubel Suter 1m37.006s + 0.865s
17. Dominique Aegerter Suter 1m37.011s + 0.870s
18. Roberto Rolfo Suter 1m37.047s + 0.906s
19. Xavier Simeon Moriwaki 1m37.108s + 0.967s
20. Simone Corsi Motobi 1m37.140s + 0.999s
21. Sergio Gadea Pons Kalex 1m37.237s + 1.096s
22. Yuki Takahashi Tech 3 1m37.252s + 1.111s
23. Michael Ranseder Suter 1m37.262s + 1.121s
24. Yonny Hernandez BQR 1m37.277s + 1.136s
25. Alex Debon FTR 1m37.307s + 1.166s
26. Claudio Corti Suter 1m37.403s + 1.262s
27. Raffaele de Rosa Tech 3 1m37.511s + 1.370s
28. Alex Baldolini ICP 1m37.541s + 1.400s
29. Axel Pons Pons Kalex 1m37.551s + 1.410s
30. Mike di Meglio Suter 1m37.567s + 1.426s
31. Fonsi Nieto Moriwaki 1m37.577s + 1.436s
32. Vladimir Ivanov Moriwaki 1m37.587s + 1.446s
33. Ratthapark Wilairot Bimota 1m37.697s + 1.556s
34. Ricard Cardus Bimota 1m37.727s + 1.586s
35. Ferruccio Lamborghini Moriwaki 1m37.953s + 1.812s
36. Anthony West MZ 1m38.088s + 1.947s
37. Joan Olive Promoharris 1m38.270s + 2.129s
38. Robertino Pietri Suter 1m38.664s + 2.523s
39. Valentin Debise ADV 1m39.100s + 2.959s
40. Mashel Al Naimi BQR 1m39.182s + 3.041s
41. Yannick Guerra Moriwaki 1m39.318s + 3.177s
42. Hiromichi Kunikawa Bimota 1m40.686s + 4.545s