Championship leader Fernando Alonso has taken pole for the second race running, holding off the challenge of both Red Bulls at a wet Hockenheim.
The Ferrari man left it late to snatch pole from Mark Webber - the top two both set their quickest times inside the final minute - before Vettel then displaced Webber with his final lap.
Home favourite Sebastian Vettel was at the top heading into the final minute but could not better Alonso and will start second.
McLaren again struggled in the wet conditions and ended 3.5s off the pace, Jenson Button managing seventh and Lewis Hamilton eighth.
Alonso's Ferrari teammate Felipe Massa did not make Q3 and will start 14th on the grid.
The top three were clear fastest, with fourth-placed Michael Schumacher nearly a full second behind Webber.
The top ten in full:
1. Alonso
2. Vettel
3. Webber
4. Schumacher
5. Hulkenberg
6. Maldonado
7. Button
8. Hamilton
9. Di Resta
10. Raikkonen