Thousands of mainly Muslim women have marched in the Austrian capital in support of Islamic headscarves and veils after the government agreed to ban the garment in public places.

Between 2,000 and 3,000 took part in the rally in Vienna under the slogan: “MuslimBanAustria – My Body, My Right to Self-Determination”, Kurier reports. Demonstrators called for the law to be abandoned and accusing the government of “Islamophobia”.

The nation’s governing coalition of Social Democrats (SPÖ) and conservative People’s Party agreed on the prohibition in places like in courts and schools at the end of last month.

They said the “integration law” was in the interest of appearing “ideologically and religiously neutral”. Police officers, judges and magistrates, and public prosecutors would be barred from wearing headscarves while serving the state.

“Those who are not prepared to accept Enlightenment values will have to leave our country and society”, the government declaration insists.

The agreement evolved out of integration legislation proposed by right-wing Foreign Minister Sebastian Kurz last summer. It was delayed for months by the SPÖ, before they agreed to the measures in an attempt to divert support from right-wing parties.

Trauriges Schauspieler, dass es nun "links" ist gegen den säkularen Staat zu sein. Shame on you Linkswende! pic.twitter.com/IKYyNLlnZ8 — Efgani Dönmez (@efganidoenmez) February 4, 2017

The Vienna protest was organised by a group calling themselves Muslim Youth Austria, who wrote in a statement on Facebook: “Every woman must be able to move freely in public without harassment and discrimination – no matter what she does or does not wear.”

Many of the banners at the rally sought to appropriate the language of feminism to justify the support for veil, claiming the garment is “liberating” and it is a “freedom” to cover females before men.

However, many were critical of the veil and protest, where very young girls were seen in headscarves.

Former Greens MP Efgani Dönmez, who is of Turkish origin, tweeted he found it “sad that left-wing groups had joined the march” and accused them of working against the “secular state” and for “political Islam”.

He slammed the full-body burqa and full-face niqab, insisting they have “nothing to do with religion” and come from “archaic tribal cultures that want to demean women and make them invisible”.

“Samuel Huntington’s Clash of Civilizations is partially already a reality. The conflict will worsen rather than relax,” he added.

France passed a similar ban more than six years ago, and German Chancellor Angela Merkel recently called for a ban on the full-face veil to stop “parallel societies” developing.