LEWIS HAMILTON pushed his patched-up car to the limit in Bahrain Grand Prix qualifying before being pipped for pole in the final seconds.
The British ace, who had to use a spare chassis after damaging his McLaren in a high-speed crash on Friday, romped to provisional first on the grid in 1min 33.292secs.
But Pole Robert Kubica set a stunning lap of 1:33.096 in his BMW Sauber to claim a debut pole ahead of Felipe Massa - the first time since October 2006 a Ferrari or McLaren hasn't qualified first.
Championship leader Hamilton will start third alongside Ferrari's Kimi Raikkonen.
With teams no longer allowed to bring a spare vehicle engineers had to work overnight on Hamilton's car.
Lewis said: "The Ferraris have outstanding pace but I knew I would still be able to challenge for the front row. It was a reasonable lap and I'm looking forward to the race."
Hamilton shrugged off the effects of Friday's crash that saw him walk away unhurt after ploughing into the tyre wall at 111mph. He said: "The crash makes no difference. I just get back in the car and go faster. I went quicker through that corner in qualifying than I did on Friday."
Kubica, who finished second in Malaysia two weeks ago, came out of nowhere to emphasise Sauber's emergence as a major contender.
He said: "We have developed quite a lot and did some really good work in qualifying."
Scot David Coulthard will start way down in 17th.