France produced a stunning comeback in their World Cup play-off against Ukraine, winning 3-0 in Paris to progress to the tournament with a 3-2 aggregate scoreline.
Mamadou Sakho opened the scoring and two erroneous offside decisions balanced each other out as Karim Benzema scored shortly after seeing another effort disallowed.
And after Ukraine had Yevhen Khacheridi sent off, an unfortunate own goal by their substitute Oleg Gusev completed a remarkable turnaround for Les Bleus, who were unrecognisable from their lacklustre showing in Kiev last Friday.
The conditions at the Stade de France were causing problems early on, with several players slipping and the surface cutting up badly, and Ukraine's Ruslan Rotan was booked in the seventh minute for clumsily bringing down Franck Ribery.
Karim Benzema's poor control and pass, with team-mates well placed, saw a promising French attack break down and Paul Pogba headed Mathieu Valbuena's corner well over.
Benzema then nodded a Valbuena free-kick over as France started on the front foot, and they got a deserved opener in the 22nd minute.
Valbuena's free-kick from the right was not cleared and when Ribery's fierce low drive was blocked, Sakho followed up to lash home.
There was controversy as Benzema was initially denied a goal, the offside flag wrongly raised when he turned a low cross in with his torso from a yard out.
Valbuena's excellent drive, with minimal backlift, was tipped away by Andrei Pyatov - who had seen his national record run of clean sheets ended at eight by Sakho.
Benzema got his goal, though, in the 34th minute when he side-footed home after an almighty scramble - though on this occasion he was shown to be comfortably offside when the ball took a final touch off Valbuena's chest.
Sakho and Khacheridi were both booked in the aftermath of Roman Bezus' foul on Ribery.
Hugo Lloris saved Andriy Yarmolenko's shot in first-half injury time to keep his side two up and the tie all square on aggregate.
Ukraine were reduced to 10 men early in the second period when Khacheridi collected a second yellow card for a foul on Ribery.
Yohan Cabaye fired Valbuena's corner over and Benzema then shot wastefully over with his left foot when given a clear sight of goal.
Mathieu Debuchy's spectacular volley flew wide before Ukraine missed a glorious chance to retake the lead in the tie. Gusev's volley took a deflection off Sakho but Roman Zozulya was unable to react in time to beat Lloris.
Pyatov pushed away Cabaye's swerving effort but France soon had the vital third goal.
A good strike from Patrice Evra was pushed away by Pyatov but Pogba laid the ball off to Ribery, whose deflected shot was unwittingly turned in by Gusev with Sakho lurking at the far post.
Ribery could not get Benzema's pass under control and skied a shot over when off balance.
Pyatov magnificently saved from unmarked substitute Olivier Giroud and the Arsenal striker powered another header over.
Ukraine's last chance disappeared with Yaroslav Rakitsky's well-struck volley straight down Lloris' throat and it was Didier Deschamps' side who were left looking ahead to a summer in Brazil.
– France head coach Didier Deschamps.
It's the magic of football.
Four days ago we were bad, very bad, but the players responded well. Tonight we played very well.
It was very important for French football that we are in Brazil next summer. We will be there, that is very good.
We were up against a good team and we showed a lot of heart and enthusiasm. When you have these basic ingredients, you can achieve good things.