France scored twice in the final 11 minutes in Brasilia to beat Nigeria and reach the World Cup quarter-finals.
Nigeria's Emmanuel Emenike had a strike ruled out for offside before Vincent Enyeama saved Paul Pogba's volley.
But Pogba eventually headed in after an Enyeama error and Joseph Yobo diverted Mathieu Valbuena's cross into the net.
France will play the winners of Monday's late match between Algeria and Germany in the last eight at the Maracana on Friday.
The final scoreline was harsh on Nigeria, who dominated for large parts of the second half, but late mistakes from their tiring players ensured they will have to wait for their first quarter-final appearance in a World Cup.
France have pedigree in the knockout rounds, having reached at least the semi-finals on the last five occasions they have progressed past the first round at the World Cup.
Nigeria's last-16 preparations had been disrupted by a row over bonuses and, with their group victory over Bosnia-Hercegovina their only World Cup win in 11 matches, this tie was always going to prove a big ask.
But, attacking with pace down the wings through both Moses and Ahmed Musa, the Super Eagles looked threatening early on. Only a flag for offside denied the powerful Emenike the opener, when he tapped home Musa's cross.
Nigeria's goalkeeper Enyeama made the most saves of any goalkeeper in the group phase and had to be alert again to keep out Pogba's fierce close-range volley as the play swept from end to end in a first half that saw both sides look vulnerable defensively.
Juventus's Pogba was being afforded a lot of space but, as was the case all over the pitch, the final ball was all too often wasteful, with Mathieu Debuchy's shot wide the only other notable attempt in a half that promised more than it delivered.
France, the 2006 runners-up, did not make it past the group stage in South Africa four years ago but they appear to be much more united as a squad in this tournament.
That togetherness was needed as Nigeria controlled the opening stages of the second half and only a sharp stop from Hugo Lloris prevented Peter Odemwingie's low shot from giving the Africans the lead.
Against the run of play Benzema almost gave France the lead. The Real Madrid man played a neat one-two with Antoine Griezmann before seeing his shot partially blocked by Enyeama and then hacked off the line by Moses.
The introduction of Griezmann for Olivier Giroud saw France emerge more as an attacking force, with Benzema playing more centrally, and the breakthrough came when Pogba headed into an empty net after Enyeama had misjudged Valbuena's corner.
And, as Nigeria pushed for a leveller, Joseph Yobo flicked Valbuena's low cross into his own net on the day he surpassed Jay-Jay Okocha's record of nine World Cup matches for the Super Eagles.
France midfielder Paul Pogba: "I have no words to describe this feeling. The whole country is behind us and scoring that goal really liberated us. I am so happy for the team and all of France.
"To score a goal for your country, especially in such an important game as this, to get into the last eight of the World Cup is one of the best moments of my life."
Nigeria coach Stephen Keshi: "I thought the referee made a lot of mistakes and was very lenient to the French players. There was a very bad tackle on Ogenyi Onazi and he is probably out for weeks."
For the best of BBC Sport's in-depth content and analysis, go to our features and video page.
France had never met Nigeria in the World Cup before
This was the first time two African nations (Nigeria & Algeria) had reached the World Cup knockout stage
Nigeria goalkeeper Vincent Enyeama recorded the most saves of any goalkeeper in the group phase
All of France's goals during this World Cup have come from inside the penalty area
France are the first team to benefit from two own goals in the same World Cup
Latest Stories
-
Disregard Wontumi TV presenter’s misleading broadcast on Election 2024 voting date – EC
1 hour -
I’ve no plans to leave comedy for movie production, says Basketmouth
2 hours -
Akufo-Addo seeks to use Bawumia to complete Akyem Agenda– Asiedu Nketiah
3 hours -
‘Bawku conflict politicised for electoral gains’ -Martin Amidu alleges
3 hours -
‘Let industry players play the game ‘ – AOMC boss slams political interference in oil sector
3 hours -
Let’s learn from ExxonMobil, high flyers must lead the way for mergers – AOMC Boss
3 hours -
‘So many regulations, yet corruption prevails’ – Dr Riverson Oppong on OMC oversaturation
4 hours -
At least 24 dead after two boats capsize off coast of Madagascar
5 hours -
Madina MP lauds White Chapel Youth Group for championing peace ahead of elections
5 hours -
Man United settle for draw at Ipswich Town in Amorim’s first game in charge
5 hours -
GPL 2024/2025: Prince Owusu screamer earns Medeama win over Young Apsotles
5 hours -
BBC visits mpox clinic as WHO says DR Congo cases ‘plateauing’
6 hours -
Burning old TVs to survive in Ghana: The toxic trade in e-waste
6 hours -
Perfume boss admitted he ignored Russia sanctions
6 hours -
Wicked proves popular as opening set to be biggest for Broadway film
6 hours