French-born Wahbi Khazri scored the only goal of the game as Tunisia upset World Cup holders France 1-0 at the Education City Stadium on Wednesday in Qatar.
The shock victory for the Africans however was not enough for them to join the defending champions in the last 16 of the tournament.
Khazri steered home a 58th-minute winner amid a cluster of defenders for only a third victory at six World Cup tournaments for Tunisia but they were still eliminated.
France, who made nine changes for this match from the team that beat Denmark and had already booked their place in the knockout stages, finished top of Group D on goal difference from runners-up Australia, who beat Denmark 1-0 at the same time.
France now take on the runners-up in Group C, which will be concluded later on Wednesday.