The "Marriage For All" was approved by 64.1% of voters and should come into force on July 1, 2022.
Swiss voters overwhelmingly backed same-sex marriage in a referendum on Sunday, official results show.
The "Marriage For All" was adopted with 64.1% of votes in favour, according to the Federal office for Statistics, with none of Switzerland's 26 cantons voting against it.
Justice Minister Karin Keller-Sutter said the federal government "welcomes this decision because the state should not dictate how people should organise their private life."
"The Federal Council will quickly implement the will of the people," she went on. "According to current planning, the new provisions can come into force on July 1, 2022 — same-sex couples will probably be able to get married in Switzerland from this point in time."
She also noted that married women couples should then be able to "make use of the legally regulated sperm donation".
The result was largely in line with polls released in the lead-up to the ballot, which suggested that 63% of voters in the wealthy Alpine country would say yes to reform.
Switzerland is among the last Western European countries where it is still outlawed. Same-sex marriage was first approved in Europe in the Netherlands 20 years ago.
But the campaign in Switzerland, which pitted LGBT activists against conservative opponents, was highly polarised.
"When you’re favourite to win, the danger is that people in favour of the reform demobilise and suddenly, it is the opposing camp that wins. That's why despite the overwhelmingly positive polls, we are redoubling our efforts to really make sure all the people with the right to vote use it," said Olga Baranova, who manages the "Marriage For All" campaign.
Speaking before the referendum, Thierry Delessert, a historian at the University of Lausanne, who specialises in LGBT issues in Switzerland, said a yes vote would be of "huge significance".
"Until the early 2020s, what dominated was a discourse of differentiated equality," the expert told Euronews. "But marriage means full equality, with LGBT people recognised as citizens on a par with other citizens -- not just equal with fewer or particular rights."
But opponents fear the measure could erode traditional family values.
"Marriage and family are closely linked because children are born naturally only from the union of a man and a woman," says the interparty committee "No to marriage for all."
What will the reform change?
Since 2007, same-sex couples in Switzerland can get official approval for civil unions, which are not on an equal footing as marriages.
But now, following the yes vote, couples will be soon allowed to marry and also adopt children.
Lesbians couples will have easier access to sperm donations if they wanted to start a family. However, anonymous sperm donation, egg donation and surrogacy will remain prohibited.
The new legislation will also make it easier for foreign partners to get Swiss citizenship.
Why was there a referendum?
The reform had been debated for years -- it was first proposed by the Liberal Greens in 2013 -- and Swiss MPs adopted it last December.
But conservative parties immediately announced they would fight the measure with a referendum, drawing on the country's system of direct democracy.
Under the Swiss Constitution, any parliamentary decision can be submitted to a referendum provided that at least 50,000 citizens sign for it.
The referendum on same-sex marriage came from the Democratic Federal Union (UDF), a micro evangelical party, with the support of the Democratic Union of the Centre (UDC), a populist party that is part of the ruling coalition, and a Christian-democratic party (Le Centre).
"These are the same groups expressing themselves as elsewhere in Europe," said Delessert, citing "Christian conservatives" and "nationalists."
"The main difference is that in Switzerland, with referendums, it is the fifth time that the population is consulted on LGBT issues. No other [Western] European LGBT community has had to face the population's opinion on its legitimacy, on its right to exist," the expert told Euronews.
"Opponents of LGBT rights have launched a referendum each time and they have lost it each time," the historian told Euronews.
Switzerland's same-sex marriage referendum: what are the arguments on both sides?
Supporters of the bill, which include the government and parliament, say it is needed to eliminate inequality of treatment between same-sex and opposite-sex couples.
"We are leading this fight for two reasons. First, because civil marriage for all is self-evident," said Baranova.
"Switzerland is the penultimate country in Western Europe which does not yet allow same-sex marriage. So every other European country has had it for years, and for a very simple reason: there are no valid motives to deny marriage and all the rights inherent in marriage to same-sex couples," the campaigner told Euronews.
"And the second reason is that today, in Switzerland like everywhere else, you have children who grow up in families called rainbow families, so families where at least one parent doesn’t define as heterosexual. These children today do not enjoy the same legal protection as children who grow up in heterosexual families. And that, in fact, is discrimination against these children. These children are legally less well protected. So beyond the symbolic power of marriage for all, it is a legal necessity to protect families and children," Baranova went on.
But opponents of the legalisation also claim they are protecting family values.
Marc Früh, an author, educator and member of the "No to marriage for all" interparty committee, told Euronews marriage should be reserved for a man and a woman together only. "The term marriage, even before Plato, clearly refers to a man and a woman transmitting life," he said.
Drawing on his experience as an educator, he insisted that he believes children needed both a father and a mother.
"We simply can't erase fathers from the Civil Code, because that's one of the issues," Früh told Euronews, noting that under the proposed reform, the word "father" will be replaced by "the other parent."
"The mother would always be the first parent," he went on, "and I do not accept that the father becomes a secondary parent. That's a no."
Has Switzerland's same-sex marriage referendum campaign fuelled homophobia?
The campaign was "very violent" for LGBT people, according to Baranova. "The homophobia that exists in society has come to light," she said.
Among other examples, the campaigner said their posters were "torn up, tagged, burned in a way I have never seen in Switzerland".
"I've been in politics in Switzerland for twelve years. Never have I seen such violence also in large urban centres, where one might think that homophobia has declined enormously."
She added that calls to hotlines supporting victims of homophobia had soared during the referendum campaign. "Before these hotlines received one or two calls per week but at the peak of our campaign, these hotlines started to receive 1 or 2 calls per day," Baranova went on.
"After this campaign, no one will be able to say that homophobia no longer exists in Switzerland," the campaigner told Euronews.
"In Switzerland, violence is sneaky, it is verbal and consensual," said Delessert.
"It is conveyed, for instance, through horrendous posters such as one featuring a zombie above a child to show the infant will never have a daddy," the historian said.
"But here in Switzerland, apart from the very surprising COVID protests, demonstrations are not a common way of fighting authorities. In Switzerland, anti-law referendums are the way to fight authorities," the historian explained.
Opponents say their objection to gay marriage is not discriminatory. "Marriage between a man and a woman is a 'privilege' which is based, among other things, on biology. This is not discrimination," says the committee against gay marriage
On same-sex marriage, how does Switzerland compare with the rest of Europe?
In Western Europe, Italy is the only other large country where same-sex marriage is not legal, even if civil unions were introduced in 2016.
Germany and Austria were the latest Western European countries to legalise same-sex marriage, respectively in 2017 and 2019. According to Delessert, this had a major influence on Switzerland, where German speakers make up the majority of the multilingual country's population (70%).
Same-sex marriage faces fierce opposition across Eastern Europe. In many countries, including Poland and Hungary, it is constitutionally banned. Estonia allows civil unions, while the Czech Republic and Hungary recognise same-sex partnerships.
When asked why Switzerland was embracing marriage equality much later than other Western European countries, both Delessert and Baranova said it had to do with Switzerland's lengthy legislative processes.
"There is always the possibility of a popular veto and that's why such important projects take so much time. Lawmakers will seek to cement their proposals so that they do not fail at the polls and obtain a majority in Parliament -- because in Switzerland, parliamentary majorities are renegotiated for each subject," Baranova explained.
Swiss society, according to Delessert, is often evolving faster than the country's legislation.
"In Switzerland, when it comes to morals, laws come to endorse a social reality that is already well established, " Delessert said, citing the country's culture of "mandatory consensus".
The historian noted that he met many fellow Swiss citizens who were surprised to hear same-sex marriage was not already legal in their country. "They thought the matter was already settled, that there was no problem," Delessert told Euronews.
What is the situation of LGBT people's rights in Switzerland?
According to ILGA-Europe, Switzerland currently ranks 23rd on the advocacy group's rating of 48 European countries in terms of respect for LGBTI rights.
The country decriminalised homosexuality in 1942 but in some cantons, police maintained a record of gay people until the early 1990s.
Overall, Baradova described the situation of the LGBTI community in Switzerland today as "mixed."
"There has been a lot of progress over the last 20 or 30 years. Many laws have been adopted," she told Euronews.
In 2020, homophobic discrimination became a criminal offence on an equal footing with racist discrimination, a move which Baradova described as "a great step forward."
"There has been more awareness and acceptance in society but at the same time, we continue to have hate crimes. There is also a lack of prevention, typically, everything related to schools education, awareness-raising, etc." the activist told Euronews.