Raikkonen, 38, who was last on pole in Monaco last year, lost out by just 0.087s, with Mercedes’ Valtteri Bottas a staggering half a second off the pace in third as the reigning world champions struggled to get the ultrasoft tyre to work.
It ends Mercedes’ stranglehold on pole position at Shanghai, having taken P1 in each of the last six years. It was also Ferrari’s second successive front row lock-out.
The last time they achieved that feat was in 2006 at the United States and French Grands Prix, which incidentally were also Michael Schumacher’s last two pole positions.
Vettel and Raikkonen reinforced Ferrari’s dominant form in final practice by setting the pace in Q1, with Vettel a full 0.750s quicker than the leading Mercedes of Bottas in third.
Reigning world champion Hamilton, having led the way on Friday, was just over a second off the ultimate pace in sixth, as the cooler conditions in Shanghai on Saturday appeared to hamper Mercedes.
Red Bull did a tremendous job changing Daniel Ricciardo’s engine, after a suspected turbo failure in FP3, to get him out with three minutes to go in the session. The Australian had just one run and despite going wide at the hairpin, he did just enough to scrape through to Q2, two places above the drop zone.
Sergey Sirotkin wasn’t so lucky, the Williams driver missing out by an agonising 0.049s. Pierre Gasly, meanwhile, couldn’t repeat his Bahrain heroics, his final lap in Q1 only good enough for 17th for Toro Rosso.
Williams’ Lance Stroll and the Saubers of Charles Leclerc and Marcus Ericsson were the other drivers to be eliminated in the opening phase of qualifying, Leclerc having been lucky to avoid the barriers after a lairy spin out of the final corner.
Ferrari and Mercedes opted to do their first runs in Q2 on the soft tyre, as they considered their strategy options for the race.
The Prancing Horse replicated their advantage, with Raikkonen and Vettel setting an impressive pace on the more durable rubber.
Mercedes could not respond and though both Bottas and Hamilton went quicker on a second run on the same compound, they remained four- and six-tenths respectively off the ultimate pace.
Hamilton and Bottas headed back out on another set of soft tyres while Ferrari opted for the ultrasofts. This time, the Mercedes duo found more performance with Hamilton and Bottas going first and second.
Raikkonen and Vettel were both on course to go quicker, but they aborted their laps, meaning the top four drivers will start Sunday’s race on the softs.
Carlos Sainz once again left it late for Renault, scraping into Q3 at the expense of F1’s Power Rankings leader Kevin Magnussen in the Haas, with the top 10 drivers separated by just one second.
Force India’s Esteban Ocon, McLaren’s Fernando Alonso and Stoffel Vandoorne, who tried and failed to successfully make a tow work for each other, and Toro Rosso’s Brendon Hartley were the others to miss out on the pole position shootout.
Raikkonen took first blood in Q3, setting the fastest time in all three sectors, ahead of Vettel, with Bottas once again the quickest Mercedes, albeit 0.425s off the pace, with Hamilton a fraction back in fourth.
On the second runs, Bottas improved but stayed third while Hamilton aborted his lap after a mistake at the hairpin leaving the Ferraris to battle it out for pole.
Raikkonen blitzed the first two sectors but Vettel was just 0.098s adrift and when the Iceman lost time in the final sector, his team mate made no mistake to snatch pole position by just 0.087s and set a new track record.
Max Verstappen was best of the rest in fifth, ahead of Red Bull team mate Ricciardo, with Nico Hulkenberg to start seventh for the third time this season in the Renault.
Force India’s Sergio Perez, who was the only driver to do just one timed lap in Q3, Sainz and Grosjean in the Haas completed the top 10.
So advantage Ferrari then. But can they convert a first pole in Shanghai since 2004 into victory? Vettel will certainly be hoping so – no driver has ever won the first three races in a championship season and gone on to lose the title…