The UN stressed on Tuesday it was opposed to most dress codes for women, after France barred its Olympic athletes from wearing the Muslim hijab during the 2024 Paris Games.

"No-one should impose on a woman what she needs to wear or not wear," United Nations rights office spokeswoman Marta Hurtado told reporters in Geneva.

Hurtado's comment came after the French sports minister said the country's athletes would be barred from wearing headscarves during the Games, in line with the country's strict rules on secularism.

French Sports Minister Amelie Oudea-Castera repeated on Sunday that the government was opposed to any display of religious symbols during sporting events.

"What does that mean? That means a ban on any type of proselytising. That means absolute neutrality in public services," she told France 3 television.

"The France team will not wear the headscarf."

Hurtado did not address France's stance directly.

But she stressed that the international Convention on the Elimination of All Forms of Discrimination Against Women ruled out discriminatory practices.

"Any state party to the convention -- in this case France -- has an obligation to ... modify social or cultural patterns which are based on the idea of the inferiority or superiority of either sexes," Hurtado said.

"Discriminatory practices against a group can have harmful consequences," she pointed out.

"That is why ... restrictions on expressions of religions or beliefs, such as attire choices, are only acceptable under really specific circumstances," she explained.

That, she said, meant circumstances "that address legitimate concerns of public safety, public order, or public health or morals in a necessary and proportionate fashion".

In France, the issue of religious dress goes to the heart of the country's strict rules on secularism.

These are intended to keep the state neutral in religious matters, while guaranteeing citizens the right to freely practice their religion.

France's laws prohibit the wearing of "ostentatious" religious symbols in some contexts, such as in state schools and by civil servants.

It outlawed full-face coverings in 2010.

In June, France's Council of State upheld a ban on women footballers wearing the hijab.