Late goals from Antoine Griezmann and Dimitri Payet booked hosts France's place in the last 16 of Euro 2016 after overcoming stiff resistance from European Championship debutants Albania.
France next face Switzerland in Lille on Sunday with the Swiss also on the verge of reaching the knockout stage after a 1-1 draw with Romania in Paris. Meanwhile, Russia moved to the brink of bowing out (for their efforts on the field, not off it) with a 2-1 defeat to Slovakia.
Atletico Madrid forward Griezmann came off the bench in Marseille to head the opener in the 90th minute before West Ham United's Payet strengthened his reputation by smashing home a second deep into stoppage time.
Payet also struck a late winner as France opened the tournament with a nervy 2-1 win over Romania.
A relieved French coach Didier Deschamps said:
This is becoming a bit of a habit, I'd prefer us to break the deadlock a bit earlier. Until the final whistle is blown there is still a chance to win the game, especially against teams who you have to wear down.
However, two leave-it-late wins left doubts about whether Deschamps's side can repeat the feats of French sides past at the 1984 Euros and 1998 World Cup by winning on home soil.
Deschamps surprisingly left Juventus star Paul Pogba and Griezmann on the bench in the only two changes from the game against Romania.
Les Bleus only kicked into gear with Pogba and Griezmann reunited with the mercurial Payet after the break.
Speaking to French television, Griezmann said:
We needed a win to qualify, and it's done. The coach had told me that I would be a substitute. I knew it and I wanted to do what I had to do once I got on.
Payet capped another man-of-the-match performance by firing into the far corner to round off a harsh scoreline on Albania.
Swiss On The Verge, Russia On The Brink
Bogdan Stancu's penalty gave Romania the advantage at the Parc des Princes. The Swiss spurned a host of chances to score before Admir Mehmedi finally slammed home to level just before the hour mark.
Stancu is fast becoming a penalty specialist at these championships, having also scored from the spot in the 2-1 defeat to France to join Payet as the only player to score twice at the tournament so far.
But the Swiss burst back into the game when Macedonian-born Mehmedi slammed home a loose ball from a corner in the 57th minute after the Romanian defence failed to clear.
Meanwhile, Russia's troubles deepened a day after the 2018 World Cup hosts were threatened with expulsion from the competition for crowd trouble at their Group B opener against England.
Napoli's Marek Hamsik set up the opener for Vladimir Weiss and then came up with a contender for goal of the tournament by smashing into the top corner to give Slovakia a 2-0 half-time lead.
Russia pulled a goal back through Denis Glushakov late on.
The result allowed Jan Kozak's team to bounce back from an opening 2-1 defeat to Wales and leaves Russia languishing at the bottom of the group with just one point from two games.
Wales can seal top spot in the pool with victory over England on Thursday.
"This has perhaps opened up the gates to the last 16. I did well," said Hamsik
"I am very proud that I managed to score such a goal. It was brilliant."