Nigeria goalkeeper Vincent Enyeama went from hero to zero as his error helped France to a 2-0 FIFA World Cup last-16 triumph.
Enyeama, who plies his trade with Lille in the French top flight, made sensational saves from Karim Benzema and Paul Pogba, but the latter capitalised to book a quarter-final place when the keeper flapped at a 79th-minute corner in Brasilia.
A Jospeh Yobo own goal in stoppage time further compounded Nigeria's late misery.
The African nation entered the match under the cloud of a dispute over bonus payments with the Nigeria Football Federation, but Stephen Keshi's men played a full part in an entertaining goalless first half.
Emmanuel Emenike thought he put Nigeria ahead, only to fall foul of a marginal offside call, while a stunning stop by Enyeama somehow prevented Pogba from volleying France in front.
As in the first half, France weathered pressure and finished stronger - Victor Moses' goal-line clearance and further heroics from Enyeama denying Benzema either side of Yohan Cabaye clattering the crossbar.
And Pogba headed into an unguarded net before Yobo put through his own net to set up a last-eight tie for France against either Germany or Algeria on Friday.
Nigeria's pace and drive in attack left France disorganised early on and when Olivier Giroud hacked over from Benzema's 15th-minute pass, it marked a rare moment of encouragement for Didier Deschamps' team.
Emenike was similarly off-target from a promisingly placed free-kick, before the Nigeria forward was denied by a 19th-minute offside flag.
France right-back Mathieu Debuchy breathed a sigh of relief having horribly sliced a clearance to Ahmed Musa, whose low cross was touched home by Emenike at the near post.
Enyeama made a remarkable reaction save after Pogba drove forward and smashed a 23rd-minute volley goalwards on the end of Mathieu Valbuena's return cross.
A drop in tempo around the half-hour mark clearly suited France, but Debuchy could not capitalise when a patient spell of possession sent a half-chance his way.
The Newcastle United defender was wasteful again in the 40th minute having been teed up by the impressive Valbuena.
A frantic close to the half matched its opening, with France goalkeeper Hugo Lloris far from convincing behind a speculative Emenike drive.
Peter Odemwingie - the match-winner in Nigeria's decisive Group F victory over Bosnia-Herzegovina - tested Lloris with a 65th-minute drive that bounced awkwardly, while tension in the French ranks was increasingly shown by sloppy errors in possession.
But Deschamps' men came agonisingly close to leading with 20 minutes left as Benzema exchanged passes with Giroud's replacement Antoine Griezmann.
The Real Madrid forward's effort was partially stopped by Enyeama and Moses was back to hack clear as the ball looped towards the net.
Benzema's low cross was cleared for Cabaye to thunder a rasping shot against the bar and Enyeama excelled himself again to keep out a Benzema header.
But he erred from Valbuena's resulting corner as France took the lead, making a later outstanding stop to thwart Griezmann seem particularly cruel.
Nigeria's defence became disjointed in the closing minutes and Yobo's own goal under pressure from Griezmann made the defender's 101st cap one to forget.
The last five times that France have taken part in the knockout stages of the World Cup, they have reached the semi-finals or better. Now Germany or Algeria stand between this sequence continuing.
France are into the quarter-finals of the World Cup for the first time since 2006 where they will face Germany or Algeria. They were given a stern test by Nigeria however and France will likely need to start stronger in future matches if they are to threaten the semi-final or final stages.
90' + 5' FULL-TIME: FRANCE 2-0 NIGERIA
90' + 4' Substitution: Mathieu Valbuena OUT, Moussa Sissoko IN
90' + 3' That essentially ends Nigerian hopes of making the last eight while it makes the scoreline that bit more pleasant for the French who failed to get going until Griezmann came on. Will Deschamps consider giving the Real Sociedad man a start next time out after this cameo display?
90' + 1' Own Goal Joseph Yobo
GRIEZMANN HELPS MAKES IT TWO - That's game over. After a quick corner, the substitute flicks home Benzema's delivery to take the game away from Nigeria with the help of a deflection off Yobo.
90' Into the final minute of normal time and it's all going to plan for Deschamps' men. They have a corner and will be in no rush to take it.
89' Substitution: Victor Moses OUT, Uche Nwofor IN
87' The game is getting away from the Super Eagles and it looks like they're on their way out. France looking calm in possession as approach the end of the 90.
85' France are looking to extend their lead and Griezmann is the next to test Enyeama. The Lille man beats the effort away for a corner.
83' It would be cruel on Enyeama if his mistake contributed to Nigeria's exit. He's been in good form on the whole and made some crucial saves earlier in the game.
81' Nigeria have to go for it now, surely. For all their good play, France have proven more clinical. Pogba's quality has put them almost into the quarter-finals. France just need to see the game out now.
79' Goal Paul Pogba
POGBA GIVES FRANCE THE LEAD - The Juve midfielder nods France in front with 11 minutes to go. Enyeama flapped at a corner and Pogba keeps cool to glance the header in.
77' OFF THE BAR! Cabaye's effort rattles the woodwork. Unlucky from the PSG midfielder as France begin to turn the screw.
76' More French pressure as Valbuena's corner is cleared by Omeruo despite the intent of Koscielny. Benzema then sees his strike cleared off the line by Mikel.
75' We've a quarter of an hour left to play in Brasilia and, as it stands, we're heading for extra time.
72' You sense France are starting to get into their stride now. Griezmann has certainly livened things up and Nigeria are being harried into making mistakes in possession.
70' OFF THE LINE! Benzema and Griezmann link well but the Real Madrid striker sees his effort cleared off the line by Victor Moses. The first moment of real quality from France's forward line.
69' POOR CORNER. Nigeria again waste the chance to capitalise on a set piece, Odemwingie swings one in but it sails over everyone and out for a throw-in.
66' Valbuena with a teasing delivery but Koscielny is kept at bay by Yobo. Oshaniwa is then required to produce a last-ditch clearance to deny Pogba a sight on goal. Some good French pressure, are we edging close to an opener?
64' Odemwingie swings a cross into the French box but there's nobody there to take advantage before the Stoke City man has an effort on target. His fierce strike is well saved by Lloris.
62' Substitution: Olivier Giroud OUT, Antoine Griezmann IN
62' Can substitute Antoine Griezmann inject some pace and creativity into proceedings? He's on for Giroud as we enter the last half hour.
60' Emenike hits one at goal from outside the area but it veers over the bar. The Nigerian forward is yet to score at the World Cup and he never looked like doing so there.
59' Substitution: Ogenyi Onazi OUT, Reuben Gabriel IN
59' FRANCE BREAK - Valbuena bursts through and plays in Debuchy who sees his shot blocked. Encouraging play from Les Bleus.
56' The Lazio man is going to have to go off on a stretcher. Matuidi's tackle was late and looks to have ended Onazi's involvement in the game.
54' Yellow Card for Blaise Matuidi
52' Great spell from Nigeria. Ambrose neatly flicks the ball in to Moses who is well tackled by Cabaye. Varane is then required to deal with another Ambrose cross with Emenike lurking inside the area.
50' Oshaniwa is down receiving treatment after a clash with Debuchy. He'll be able to continue and is needed to help defend a French corner.
47' We're back under way...who will find that breakthrough?
It's been an entertaining first 45 minutes where Nigeria have looked to take the initiative with their attacking play. Odemwingie and Musa in particular have looked dangerous although Keshi's men have struggled to create too many goalscoring chances.
45' + 4' HALF-TIME: France 0-0 Nigeria
45' + 3' It finds the head of Koscielny and then Debuchy but neither can turn it in. Still 0-0.
45' + 2' Can France secure an opener late in the first half? They have a free-kick that Valbuena will whip in...
44' We look set to go in goalless at the break despite both sides having chances. France will be disappointed with their attacking play, with Giroud and Benzema being almost anonymous throughout, while Nigeria are ending the half strongly.
42' Pogba plays in Debuchy and, despite the overhit pass, the full-back keeps it in. However, his last-ditch cross sails over everyone. That final quality ball seems to be eluding the French.
40' WHAT A CHANCE - Valbuena clips a ball into the onrushing Debuchy but his effort is off target. The Newcastle man should possibly have done better with that despite the box being crowded with bodies.
38' A corner from Musa but again it's swung right over everyone. Replays show some overly-tight marking from Evra on Odemwingie, which the Manchester United man looks to have been warned about.
35' Pogba threads a ball into Cabaye but it slides out of play with the PSG man later adjudged offside anyway. A good period from Les Blues who are ending the half strongly.33' France are enjoying a frankly rare spell of possession here, witg Cabaye and Matuidi exchanging passes. It falls to the advancing Debuchy who fires high and wide. Better from France...until the finish that is.
30' Odemwingie threatens with a shot but it's well blocked by Koscielny. Ambrose then delivers a cross that's cleared by the Arsenal man. Can they get the breakthrough and ruffle some French feathers?
29' Pogba hits one from distance and it almost falls for Benzema. Nigeria clear though. Approaching the half-hour mark in what has been an entertaining affair so far...
26' ANOTHER CORNER FOR NIGERIA - Keshi will be eager for his charges to make the most of these opportunities but it's cleared easily by the French defence.
25' France under the cosh aerially for a spell but Lloris does well to come and command the ball. End-to-end stuff in Brasilia...we could just do with a goal really.
23' GREAT SAVE FROM ENYEAMA - Pogba bursts into the Nigeria half and, after a one-two with Valbuena, sees his effort saved brilliantly by Enyeama. Super stop.
22' That was the closest either side have come to opening the scoring but it was correctly ruled offside. Nigeria certainly on top at the minute but you sense Keshi's men will need to make the most of this spell.
19' OFFSIDE GOAL - Emenike thinks he's got the opener but it's disallowed. He's marginally off from the delivery - a let off for France.
18' The answer is no. Emenike blazes it well over the crossbar. Poor effort from the striker.
17' Onazi is back on and there's more good news for Nigeria who have a free-kick on the edge of the area. Odemwingie brought down by Matuidi. Can the Super Eagles threaten with this set piece?
15' Odemwingie whips the ball in and Mikel's header is taken well by Lloris. France break and Giroud fires over after good play down the left from Benzema.
13' Emenike wins a free-kick close to the touchline although Nigeria are more concerned with an injury to Onazi. He tangled with Pogba in a challenge. This would be a blow for Keshi...
11' Instead it's the Nigerian trio of Onazi, Musa and Odemwingie helping get Nigeria going. Some lovely passing play in the midfielder helps them keep the ball and slow the tempo down.
9' After that hectic start to the game, things have quietened down a little bit. Can France get the likes of Cabaye and Pogba on the ball to feed Benzema and Giroud?
7' STAT - This is Joseph Yobo's 10th World Cup appearance, which sees him claim the Nigerian record from previous holder Jay-Jay Okocha.
6' Ambrose's delivery is taken down by Odemwingie but the ball just falls away from him at the last minute. Nigeria getting their early joy down the right from Ambrose and Musa.
4' After a brief spell of Nigerian possession, France are back to attacking. Blaise Matuidi forcing a corner after a surge forward. It's been a very open start to the game.
3' It's been a positive start from France. Full-back Debuchy bursts down the French right only to be disposessed before his cross just fails to meet Karim Benzema shortly after. He and Evra will need carefull attention from the Nigeria backline.
1' WE'RE UNDER WAY! Nigeria kick us off, playing from right to left.
The stats seem to be against Nigeria, with Deschamps unbeaten in his nine games at the World Cup as player and manager with Les Blues. Furthermore, only three African teams have ever made it to the quarter-finals of the World Cup. Can Keshi's men upset the odds and book a last-eight meeting with Germany or Algeria?
Having rested a number of players for France's final group game with Ecuador, Didier Deschamps recalls Olivier Giroud, Mathieu Debuchy, Patrice Evra, Raphael Varane, Mathieu Valbuena and Yohan Cabaye to the starting XI. Nigeria coach Stephen Keshi is forced into one change due to the fractured wrist suffered by Michael Babatunde - Victor Moses the man to replace him.
NIGERIA SUBS: Ejide, Agbim, Odunlami, Egwuekwe, Uzoenyi, Azeez, Gabriel, Ameobi, Uchebo, Nwofor
NIGERIA STARTING XI: Enyeama, Yobo (c), Ambrose, Musa, Odemwingie, Emenike, Mikel, Moses, Oshaniwa, Onazi, Omeruo
FRANCE SUBS: Landreau, Ruffier, Mangala, Sagna, Digne, Mavuba, Sissoko, Schneiderlin, Cabella, Griezmann, Remy
FRANCE STARTING XI: Lloris (c), Debuchy, Evra, Varane, Cabaye, Valbuena, Giroud, Benzema, Matuidi, Pogba, Koscielny
COMMENTARY: Goal dot com