Maria Sharapova suffered a first defeat since returning from a 15-month doping ban as Kristina Mladenovic beat her in the semi-finals of the Stuttgart Open.
Five-time Grand Slam winner Sharapova was up a set and a break but squandered it to lose 6-3 5-7 4-6.
Mladenovic faces Romanian Simona Halep or German Laura Siegemund in the final.
Having been given a wildcard entry, Russian Sharapova needed to reach the final in Germany to be eligible for qualifying for the French Open.
Her defeat means she will finish outside the top 200 when the rankings are released on Monday, ruling out a qualifier spot for the event in Paris, which starts on 22 May.
She will learn on 16 May whether she will be given a wildcard for the main draw at Roland Garros.
Sharapova, who has also received wildcards for forthcoming tournaments in Madrid and Rome, took complete control at the start of the contest as a second double fault gave the 30-year-old a 4-1 lead before sealing the first set in just 38 minutes.
She broke Mladenovic again at the start of the second set and looked to be cruising to victory, but despite conceding 11 double faults, the Frenchwoman improved her baseline game and fought her way back into the contest.
The world number 19 broke back and then held her composure to survive three break points to go 6-5 ahead before converting her first set point on Sharapova’s next service game.
The pair traded blows early in the third before Mladenovic grabbed a break to go 4-2 up before fighting back from 0-40 to hold her serve.
Mladenovic seized the advantage in the final set by converting her fourth break point and then coming from 40-0 down in the seventh game to take a commanding 5-2 lead.
Sharapova rallied to pull it back to 5-4, but Mladenovic was not to be denied her first win over the Russian and converted her first match point.