Tunisia registered a shock victory after France had a goal ruled out by the VAR in the final minute of injury time.
They did not qualify for the last 16 of the World Cup.
The VAR decision meant that the Tunisia captain's brilliant first-half goal proved to be the winner.
Tunisia's hopes of progressing were dashed by Australia's victory over the Danes in the other match in the group.
Tunisia manager Jalel Kadri said that they were happy to beat France.
It is a bitter victory, but we can be proud.
It would have been great to beat France and make it to the last 16. It's our fault that we didn't do what we were supposed to do.
France are through to the last 16 as group winners having already secured qualification.
Despite their failure to progress, Tunisia captain Khazi produced the moment fans had been waiting for - a goal at this World Cup - when he drove to the edge of the box.
There was a lot of emotion from the Tunisia fans at the stadium, while the Tunisia substitute sprinted onto the pitch in a moment of pure joy.
When news of Australia's lead began to spread through the stadium, supporters checked their phones for updates from the other match in the group.
France, who had already qualified for the next round, lacked quality in their performance.
The two forwards were brought on to try and get back into the game.
Despite loud jeers and whistling from Tunisia fans, they had an impact even though they wanted to stop them.
The winner of Group C will face the runner-up in the last 16 on December 4.
Tunisia has yet to make the knockout stages of the World Cup for the first time.
Tunisia knew they needed to win the game to progress, and they started with a lot of intent.
Eduardo Camavinga needed support from Ibrahima Konate when he was overloading out wide.
The support for Tunisia was far greater than France's and the majority of them celebrated when the volley flew past the goalkeeper, only to be ruled out for an obstruction.
As the first half wore on, Tunisia fans' impatience began to show - though their support remained relentless - as chance after chance came, but goalkeeper Mandanda did not look like he had conceded the game.
Then a wonderful moment from Khazri opened up space for himself on the edge of the box and his strike beat Mandanga in the bottom corner.
Tunisia fans were full of hope as they were heading into the last 16 but two minutes later, Australia's goal took it away from them.
Nothing is impossible. Kadri said that they had won over the world champion.
We proved our efficiency and did our best. The team worked together. It wasn't easy for us to get these four points, but we leave with a lot of pride and honor.
France were on top of their game in the second half because Deschamps didn't waste a lot of time bringing on the two superstars.
Tunisia had a number of corners late in the game, but they were unable to get a goal.
The referee went to the pitchside monitor to watch the VAR and the goal was ruled out.
There is a formation 3-4-2-1.
21Kechrida17Skhiri14Laïdouni12Maâloul25Ben Slimane15Ben RomdhaneFormation 4-3- 3.
3Disasi4Varane24Konaté25Camavinga13Fofana8Tchouaméni15Veretout20Coman12Kolo Muani6GuendouziThe match ended with Tunisia defeating France 0.
Tunisia leads France by one at the end of the second half.
The no goal decision was made by the VAR.
The goal was ruled out by the VAR after it was scored.
It's France. Aurélien Tchouaméni tried a through ball, but was unsuccessful.
There is a corner in France. There was a disagreement between Yassine Meriah and the other person.
Eduardo Camavinga takes a free kick.
The person is foul by the person.
There is a corner in France. Wajdi Kechrida was involved in the match.
The attempt was saved. Kylian Mbappé's shot was saved in the bottom right corner.
The attempt was blocked. A shot from outside the box is blocked by a defender.
A free kick is won by Kylian Mbappe.
The foul was committed by Ghaylen Chaalali.
There is a corner in France. The man was Conceded by the man
The attempt was blocked. The shot is blocked by the box. It was assisted byAntoine.
The attempt was saved. Kylian Mbappe's shot was saved in the top right corner. Eduardo Camavinga assisted
The free kick was won by Ibrahima Konaté.
The person is foul by the person.
The attempt was not successful. The shot from the left side of the box missed to the right. The assisted by Ousmane Dembélé.
There was a substitution in Tunisia. Ali Abdi is the new one.
Get the latest results and goal notifications for any team at the Fifa World Cup by downloading the BBC Sport app: Apple - Android - Amazon
You can get a daily dose of the World Cup on the radio.