The first half of qualifying was run in the dry, but showers arrived midway through Q2 to force teams on to intermediate tyres.
The German had only squeaked through Q1 and Q2, but found the pace when he needed it most to overcome the threat from Ferrari.
Felipe Massa was 0.913 seconds behind in second, but outqualified his team-mate Fernando Alonso for the fourth Grand Prix in a row.
Malaysian Grand Prix
Final Malaysian GP starting grid
23/03/2013 AT 18:24
Lewis Hamilton led as qualifying drew near to a close, but his final lap was disappointing as others surged past.
Mark Webber was some way adrift in fifth, separating Hamilton from his Mercedes team-mate Nico Rosberg.
Kimi Raikkonen again qualified seventh ahead of Jenson Button, Adrian Sutil and Sergio Perez.
But the Australian GP winner will start 10th on the grid after he was adjudged to have blocking Rosberg's Mercedes at Turn 14 and given a three-place grid penalty.
"If you start in the front, you always want to finish there as well," Vettel told reporters after his 38th career pole and second of the season.
"It will be a long race and it's difficult to know the true pace. We confirmed what we saw in Melbourne. I'm happy with the balance of the car."
https://i.eurosport.com/2013/03/23/975981.jpg
Conditions had grown steadily more overcast in the Malaysian late afternoon, but remained dry and hot.
The drivers did not rush out in Q1, opting instead to keep qualifying runs to a minimum and preserve their tyres for the race.
Red Bull and Lotus ran just once on the softer, medium compound tyres. The ploy worked for Lotus, slipping effortlessly into the front behind surprise Q1 pace-setter Adrian Sutil, but Red Bull were considerably less assured, with Webber needing a late lap to slot in ninth and Vettel squeaking through to Q2 in 15th place.
Q2 began in the dry, but with the threat of rain on the radar.
Drivers set out early, with Mercedes, Ferrari and McLaren getting their two drivers safely through. Red Bull also managed the feat, though Vettel was once again close to elimination, finishing ninth.
Romain Grosjean, stranded in 11th, was the highest-profile casualty of the session once the rain hit midway through the session.
Paul Di Resta, whose Force India looked quick, was also a victim of conditions – he abandoned a fast lap early in the session for a tyre change, only to discover that when he ventured back out that the first spots of rain had made the conditions too slippery to break into the top 10.
Intermeidate tyres were the best fit for Q3, as the rain began to ease and the circuit quickened by the minute. The cars queued up at the pit lane exit in a bid to get the best early position at the start of the session, but in the end it was the performance at the death which mattered.
Vettel made a switch to a fresh set of intermediates, and it paid off, with the German finding considerably more pace than his rivals.
The Red Bull flattered to deceive on race day in the Australian Grand Prix, and with rain again a potential factor on Sunday Vettel's pole position is far from guaranteed to turn into his first win of the campaign.
Formula 1
Mercedes duo believe pole was possible
23/03/2013 AT 10:26
Formula 1
Deal agreed to keep Dutch GP on F1 calendar to 2025
YESTERDAY AT 09:04