Hosts France were made to work hard by Albania but two late goals sealed the Group A match in their favour.
Antoine Griezmann and Dimitri Payet scored late to earn the nervous hosts the result they sought.
Griezmann, who came in as a second half substitute, headed France ahead in the 90th minute before the in form Payet added a second deep into extra time.
The 2-0 win, at the Stade Velodrome in Marseille, made France the first team to qualify for the knockout stages.
France failed to break down a resolute Albanian defense for 90 minutes, before Griezmann scored.
It was yet another unconvincing display from the hosts, who looked tight in a last-gasp 2-1 win against Romania at the Stade de France in the opening game of the tournament last week,
However, victory in that game was thought to have given them the confidence they needed after two years without playing a competitive game.
Paul Pogba and Griezmann were rested for the game, with coach Didier Deschamps has handed starts to Kingsley Coman and Anthony Martial. However, the duo had to be called upon, along with striker Andre-Pierre Gignac - in for an off-target Olivier Giroud - in the second half as France looked for that elusive goal.
However, Albania, even without their suspended captain Lorik Cana - who was sent off against Switzerland - took a conservative approach and held fort for much parts.
Albania probably drew confidence from their friendly defeat of France in Elbasan a year ago. Seven months earlier, the teams had drawn 1-1 in Rennes.
At their first match in a major tournament, Albania made a timid start, conceding in five minutes to Switzerland, having captain Lorik Cana sent off and missing several chances to equalise.
However, they were at their resolute best against the two-time champions. It took the French all their resolve to grind out the result.
Euro: Switzerland draw with Romania to edge closer to last 16
Euro: Slovakia make life difficult for Russia with 2-1 win
What Wales must do to cope with new Rooney role...
Ronaldo slams Iceland's 'small mentality'; they tell him to stop whining
Tonight Anglo-Welsh rivalry will reach new peak!