Substitute Antoine Griezmann eased France's frustration in Marseille with a 90th-minute header, before Dimitri Payet made certain, as Les Bleus overcame a dogged Albania side to become the first team into the UEFA EURO 2016 knockout stage.
Didier Deschamps' men were running out of time and ideas when Griezmann met Adil Rami's cross from the right, breaking Albanian hearts. Payet curled in a second in the sixth minute of additional time, giving the Group A scoreline a somewhat flattering look.
Gianni De Biasi's disciplined charges had made light of the absence of their suspended captain, 91-cap former Marseille player Lorik Cana. Set up in a 4-5-1 system, they did their best to quell the partisan crowd. Albania negotiated the first period with little cause for alarm, their relative comfort highlighted by the fact their opponents failed to register a shot on target.
France survived a scare early in the second half when they laboured to deal with Armando Sadiku's cross into the area, the ball hitting Bacary Sagna and striking Hugo Lloris's left-hand upright.
Substitute Paul Pogba blazed over as the contest became increasingly frenetic, before the in-form Olivier Giroud headed a Patrice Evra centre against a post. They were saved by Griezmann, Payet's effort then icing the cake.
Man of the match: Dimitri Payet
France's match winner on opening night, the excellent No8 did it again as he capped an impressive display with the last-gasp drive that clinched it on his old Marseille stomping ground. His set pieces caused Albania plenty of problems and he created six openings for team-mates. He was No1 on the Player Barometer before today; he will take some shifting on this evidence.
Hot streak ends
Giroud entered the game having scored eight goals in his last six starts. He spurned his best opportunity after 68 minutes, glancing wide Kingsley Coman's left-wing delivery. Moments later the No9 rattled the woodwork, an unsatisfying evening's work abbreviated when he was replaced by local favourite André-Pierre Gignac with 14 minutes left.
Deschamps' dalliance with 4-2-3-1 – he had drafted in Coman and Anthony Martial for Griezmann and Pogba respectively – did not last long. With France having lacked any sort of fluency, Martial made way for Pogba at the break and immediately the two-time winners asked more questions of Albania.
'Une ambiance extraordinaire'
Stade Vélodrome had witnessed a couple of memorable France victories – the extra-time thriller against Portugal in the EURO '84 semis and the 3-0 defeat of South Africa in the hosts' 1998 FIFA World Cup opener. Tonight was another, the 68,000 fans helping to generate what Emmanuel Petit, who played in that latter match, referred to in Wednesday's edition of regional newspaper La Provence as the stadium's "awesome atmosphere".
Team reporters' views from Stade Vélodrome
David Crossan, France (@UEFAcomDavidC)
After a lacklustre first half, France improved in the second, looking more comfortable and more energetic following the reversion to a 4-3-3 formation. They got their reward late on, but overall did not muster enough attempts on target.
Tony Pandovski, Albania (@UEFAcomTonyP)
Having made three changes, De Biasi fielded a side with a lot of energy. Wingers Andi Lila and Ledian Memushaj offered more speed, strength and a threat on the break. Organised defensively, Albania almost survived against a star-studded French outfit.