Jorge Lorenzo captured his fifth pole of the season as MotoGP qualifying built to a three-way shootout at Aragon.
The Spaniard edged out championship rival Dani Pedrosa by just eight hundredths of a second, with Cal Crutchlow - on top for much of the running - a further 0.1s back in third.
All three riders had set personal bests in the first sector of their final efforts, but ultimately lost time over the rest of their laps.
The upshot was that Lorenzo hung on to pole, having only moved to the top in the final two minutes.
Pedrosa meanwhile was able to bounce back from an early crash, and the disadvantage of switching to his second Honda, to also soar in the final moments.
Crutchlow, by contrast, had made his move at the halfway mark and spent much of the session more than six tenths clear of the field.
As Lorenzo and Pedrosa made their charge he also improved, but fell just short of what would have been his first MotoGP pole.
Ben Spies made it three Yamahas in the top four, finishing less than four tenths of a second down on his works team-mate.
Honda's Stefan Bradl (LCR) and Jonathan Rea meanwhile put in notable performances to seal fifth and seventh, sandwiching the second Tech 3 of Andrea Dovizioso.
In only his second MotoGP qualifying session, Rea was therefore able to outpace both works Ducatis.
A difficult session for the Desmosedici was compounded as Valentino Rossi and Nicky Hayden both suffered falls. Rossi dropped his bike at Turn 2 with 25 minutes gone, while Hayden lost his two minutes from the end, ending the session clasping his already injured right hand.
A late effort on his second bike was enough to carry Rossi above Hayden and into eighth, while Hector Barbera on the satellite Pramac Ducati also threatened but ultimately had to settle for 10th.
Aspar's Aleix Espargaro finished as the top CRT rider in 11th, having leapt into ninth, ahead of Rossi, with just over one minute to run.
Pos Driver Team/Bike Time Gap 1. Jorge Lorenzo Yamaha 1m49.404s 2. Dani Pedrosa Honda 1m49.492s + 0.088s 3. Cal Crutchlow Tech 3 Yamaha 1m49.576s + 0.172s 4. Ben Spies Yamaha 1m49.748s + 0.344s 5. Stefan Bradl LCR Honda 1m50.034s + 0.630s 6. Andrea Dovizioso Tech 3 Yamaha 1m50.241s + 0.837s 7. Jonathan Rea Honda 1m50.410s + 1.006s 8. Valentino Rossi Ducati 1m50.949s + 1.545s 9. Nicky Hayden Ducati 1m51.013s + 1.609s 10. Hector Barbera Pramac Ducati 1m51.072s + 1.668s 11. Aleix Espargaro Aspar Aprilia 1m51.082s + 1.678s 12. Alvaro Bautista Gresini Honda 1m51.155s + 1.751s 13. Randy de Puniet Aspar Aprilia 1m51.459s + 2.055s 14. Karel Abraham Cardion Ducati 1m51.521s + 2.117s 15. Michele Pirro Gresini FTR-Honda 1m52.606s + 3.202s 16. Mattia Pasini Speed Master Aprilia 1m52.638s + 3.234s 17. Colin Edwards Forward Suter-BMW 1m52.853s + 3.449s 18. Danilo Petrucci Ioda Suter-BMW 1m53.140s + 3.736s 19. Yonny Hernandez Avintia FTR-Kawasaki 1m53.233s + 3.829s 20. James Ellison Paul Bird Aprilia 1m53.719s + 4.315s 21. David Salom Avintia FTR-Kawasaki 1m55.290s + 5.886s