Berlin has become the first German city to legalize circumcision for religious reasons, ending months of legal uncertainty about the ritual practice in the European country.
"We explicitly welcome Jewish and Muslim life in Berlin,” Thomas Heilmann, Berlin's senator for justice, said in a statement cited by Reuters.
“This applies also to the practice of their religions.”
Unveiling guidelines for the practice, officials said circumcising boys was legal if parents had given their permission and been informed about the risks of the operation.
The parents had to prove their affiliation to a religious group and a doctor had to perform the circumcision.
"If these criteria are fulfilled, circumcision will remain immune from prosecution," Heilmann said.
"If medical standards are observed, circumcision at home or in a synagogue is also acceptable."
The new guidelines came after two months of legal uncertainty about the practice since a court in the state of Cologne ruled that circumcision amounted to a bodily harm and thus a crime.
The verdict followed the circumcision of a four-year-old Muslim boy by a German doctor on his parents' wishes.
The court argued that the four-year-old boy was not old enough to consent to have part of his body removed permanently and his parents should have let him decide when he got older.
The controversial verdict sparked outrage among Muslim, Jewish and Christian leaders, who denounced the ruling as a serious intrusion on religious freedom.
The ruling triggered a highly charged debate in Germany over infants' and parents' rights, religious freedom and the practice of circumcision itself.
The verdict also prompted doctors across Germany to refuse to carry out circumcision operations because of what they saw as a risk of legal action.
Germany is home to nearly four million Muslims and about 120,000 Jews. Satisfactory
The new guidelines won plaudits in Germany.
Kristof Graf, the medical director of the Jewish Hospital in Berlin, told Agence France-Presse (AFP) that he was "satisfied with the solution".
He said his facility normally performs 80 to 100 circumcisions a year, but had conducted none since the Cologne court ruling.
The German government is already working on a new law to legalize circumcision across the European country and overrule the Cologne verdict.
Circumcision is a confirmed Sunnah in Islam as an act pertaining to fitrah (pure human nature).
The practice is also mandatory for Jewish males according to biblical texts.
Others use the practice for hygiene purposes, generally among infant boys.
Jews circumcise male infants eight days after birth to recall their covenant with God.
The time for Muslim circumcision varies according to family, region and country.
Thousands of young boys are circumcised every year in Germany, especially in the country's large Muslim and Jewish communities.
The World Health Organization has estimated that nearly one in three males under 15 is circumcised.