Islamic dress has long been hot-button issue in secular France, where full-face veil is banned in public places
The French resort of Cannes won court backing for its "burqini ban" on Saturday as a judge refused to overturn its decision to forbid Muslim women from wearing the full-body swimsuit.
Local authorities in the Riviera city, home to the famous Cannes film festival, moved to ban burqinis from beaches at the end of July. The nearby resort of Villeneuve-Loubet followed suit on Saturday.
Three women backed by the Collective Against Islamophobia in France (CCIF) challenged the Cannes decision in court on Friday, saying it was illegal and calling for it to be suspended.
But a court in Nice rejected the request, saying the move was legal under French law forbidding people from "invoking their religious beliefs to skirt common rules regulating relations between public authorities and private individuals".
The judge noted that the Cannes ban had been declared "in the context of the state of emergency and recent Islamist attacks, notably in Nice a month ago".
"The wearing of distinctive clothing, other than that usually worn for swimming, can indeed only be interpreted in this context as a straightforward symbol of religiosity," the ruling said.
CCIF lawyer Sefen Guez Guez said he would appeal the decision before France's highest administrative court, adding: "This decision opens the door to a ban on all religious symbols in the public space."
Anti-racism groups have expressed outrage at the burqini bans, which come at a highly sensitive time following a series of militant attacks in France.
Islamic dress has long been a hot-button issue in secular France, where the full-face veil is banned in public places. But there is no ban on wearing religious symbols or clothing.
Cannes mayor David Lisnard said he had signed off on the burqini ban out of "respect for good customs and secularism", a founding principle of the French republic.
In nearby Villeneuve-Loubet, mayor Lionnel Luca had a different justification for banning the garment, saying he made the decision for sanitary reasons.
"I was informed that there was a couple on one of our beaches where the wife was swimming fully dressed," said.
"I considered that unacceptable for hygienic reasons and that in general it was unwelcome."
He disputed charges that the burkini ban was discriminatory, saying it was intended "to avoid any disturbance to public order in the region which was hit by attacks".
Burqinis have also been in the headlines in France this week after a waterpark in the city of Marseille cancelled plans to host a private event for women wearing burqinis, following a public uproar.
France has been hit by three major terror attacks in 18 months, and the Islamic State (IS) group claimed two assaults on French territory in July.
On 14 July Nice was the target of an attack claimed by IS that killed 85 people, when an Algerian ploughed a truck into crowds celebrating Bastille Day.
And on 26 July, a priest was killed in his church in northwestern France by two attackers who had proclaimed their allegiance to IS.