Croatia and the Netherlands booked their places in the last four of the Nations League as holders France needed a favour to avoid relegation from the top tier on Sunday.
Les Bleus lost 2-0 in Denmark to finish with just one win from their six group games, but Croatia's 3-1 win at Austria saved the world champions from the drop.
Didier Deschamps will be hoping to have a number of key men back from injury by the time France's defence of the World Cup begins against Australia on November 22.
"It was a young French team, which for the most part does not yet have experience of the highest level," said Deschamps.
"Tonight is a dose of reality and what will be waiting for us in two months."
France will also come up against the Danes in the group stage in Qatar and the Euro 2020 semi-finalists showed they are more than capable of causing more trouble in two months' time.
Both goals came before half-time as Kasper Dolberg stretched to turn home Mikkel Damsgaard's cross before Andreas Skov Olsen volleyed in from the edge of the area.
France were without Hugo Lloris, Jules Kounde, N'Golo Kante, Paul Pogba, Ousmane Dembele and Karim Benzema through injury.
But the star trio of Antoine Griezmann, Olivier Giroud and Kylian Mbappe failed to find a way back into the game for France.
Denmark's win meant Croatia needed to get all three points in Austria to top the group.
Luka Modric got the 2018 World Cup finalists off to a flying start, but they were quickly pegged back by Christoph Baumgartner's header.
Two goals in three second-half minutes proved decisive as Marko Livaja and Dejan Lovren headed in at the far post.
"Austria made our lives very hard, but in the end, the win was deserved," said Modric. "I am very happy that we are in the top four."
Defeat relegated Austria to League B.
The Netherlands made sure of top spot in Group A4 with a 1-0 win over Belgium thanks to Virgil van Dijk's header 17 minutes from time.
The Dutch just needed to avoid defeat by a three-goal margin after winning 4-1 in Brussels earlier in the group.
A Belgian revival never looked likely. Van Dijk settled the game when he was left completely unmarked to head in a corner inside the six-yard box.
In the same group, Wales were relegated after losing 1-0 at home to Poland.
Karol Swiderski scored the only goal in Cardiff from Robert Lewandowski's cushioned through ball.
Turkey were already guaranteed promotion from League C, but were still embarrassed by a 2-1 defeat to the Faroe Islands.
The Faroes led 2-0 through Viljormur Davidsen and Joan Edmundsson before Serdar Gurler's late consolation for the side ranked 83 places higher in FIFA's world rankings.
COMMENTS
Comments are moderated and generally will be posted if they are on-topic and not abusive.
For more information, please see our Comments FAQ