Ousmane Dembélé has been ruled out of the European Championship because of a knee injury, the French soccer federation said Monday.

Dembélé sustained the injury during a 30-minute appearance as a substitute before being replaced late in the team’s 1-1 draw with Hungary on Saturday.

The French team said Dembélé had X-rays at a hospital in Budapest on Sunday.

France's Adrien Rabiot, left, is replaced by Ousmane Dembele during the Euro 2020 soccer championship group F match between Hungary and France, at the Ferenc Puskas stadium in Budapest, Saturday, June 19, 2021. (AP PhotoDarko Bandic, Pool)

France's Adrien Rabiot, left, is replaced by Ousmane Dembele during the Euro 2020 soccer championship group F match between Hungary and France, at the Ferenc Puskas stadium in Budapest, Saturday, June 19, 2021. (AP PhotoDarko Bandic, Pool)

“The length of recovery time needed is incompatible with keeping him in the squad,” the team said.

Teams can replace injured goalkeepers but not outfield players once they have played their first match in the tournament.

Dembélé’s exit means France coach Didier Deschamps will have only 25 players to choose from for the rest of Euro 2020. France leads Group F and will next face Portugal in Budapest on Wednesday.

Dembélé’ plays for Barcelona. The French federation said its doctors talked with staff at the Spanish club before making the decision to release him.

The 24-year-old Dembélé was a member of the France squad that won the 2018 World Cup.

More AP soccer: https://apnews.com/hub/soccer and https://twitter.com/AP_Sports