Lewis Hamilton beats Nico Rosberg in Bahrain final practice

Lewis Hamilton beat Mercedes team-mate Nico Rosberg in final practice at the Bahrain Grand Prix as Red Bull's Sebastian Vettel spun off the track.

The world champion lost control on the kerb at Turn Two and spun into the gravel, ending his chance of doing a run in preparation for qualifying.

Lewis Hamilton: Mercedes team-mate Rosberg is my main rival

Vettel ended up 21st as Hamilton edged out Rosberg by 0.115 seconds.

Force India's Sergio Perez was third from the Williams cars of Valtteri Bottas and Felipe Massa.

Ferrari's Fernando Alonso was the fastest car not fitted with a Mercedes power-unit in seventh place behind Jenson Button's McLaren.

The next was the Renault-engined Toro Rosso of Daniil Kvyat in ninth, behind Force India's Nico Hulkenberg.

Ferrari's Kimi Raikkonen lagged behind team-mate Alonso for the third consecutive race since returning to the Italian team, 0.318secs slower than the Spaniard.

McLaren's Kevin Magnussen was 11th from the Toro Rosso of Jean-Eric Vergne and the Red Bull of Daniel Ricciardo, who will be demoted 10 places on the grid from wherever he qualified following a penalty for an unsafe release from a pit stop in Malaysia last weekend.

Sebastian Vettel

Hamilton's performance means he has topped all three of the practice sessions so far in Bahrain. He appears to be in strong shape ahead of qualifying, which starts at dusk under lights for the first time in Bahrain at 1600 BST.

BBC F1 analyst Allan McNish said: "The battle behind the Mercedes team of Hamilton and Rosberg is going to be fantastic.

"And who's going to get pole? That's a big psychological battle here. Right now, those two guys are fighting among themselves. Everyone else is fighting for the final step on the podium."

Perez, who had one of his best races for McLaren last season here, was 0.544secs behind Hamilton and 0.248secs ahead of Bottas.

Pastor Maldonado pulls a wheelie

Alonso was 1.13secs off the Mercedes pace and admits he is fighting for scraps while his team try to catch up with Mercedes.

"We are not in the best position we wanted," said Alonso, who finished runner-up to Vettel in the championship three times in the last four years and last won a title in 2006.

"I would like to be in race three with some podiums and victories; we were not able to do so.

"We need to raise our game, even if this weekend we know it is going to be difficult. The characteristics of the circuit are probably not in our favour with traction corners and top speed so we expect tough competition with Mercedes, McLaren, Williams, which was super-strong in winter testing."

Bahrain Grand Prix Final Practice results

Full Bahrain Grand Prix coverage details