LGBT campaigners have reacted with anger and dismay after judges at Kenya’s high court rejected a bid to repeal colonial-era laws criminalising gay sex.

The ruling has dealt a major setback to campaigners, who hoped that scrapping the laws would inspire other countries in Africa – where discrimination is widespread – to do the same.

A bench of three judges told a packed courtroom in Nairobi they had not seen sufficient evidence of discrimination caused by the laws, which they said were constitutional because they represented the values and views of the country.

Justice Roselyne Aburili rejected last year’s precedent in India, which legalised gay sex between consenting adults, as well as a series of other judgments across the Commonwealth and elsewhere, and said Kenya should make its own laws to reflect its own culture.

Aburili said same-sex couples living together would be violating the constitution and that there was no scientific proof LGBT people were “born that way”.

“Courts should be loath to fly in the face of public opinion,” she added, amid chaotic scenes at the high court, where media, supporters and lawyers packed the narrow corridors on Friday. Some activists wept outside the courtroom once news of the ruling had filtered through.

The judgment stems from a petition filed by gay activists in 2016 that argued that the laws, which punish sexual acts deemed “unnatural” with up to 14 years in prison, contravene Kenya’s 2010 constitution and encourage discrimination.

“These old colonial laws lead to the LGBT community suffering violence, blackmail, harassment and torture,” the Nairobi-based National Gay & Lesbian Human Rights Commission said after the decision was announced. “They devastate people’s lives and have no place in a democratic Kenyan society.” Paul Muite, a lawyer for the commission – the main petitioner in the case – said it would appeal.

Stonewall UK called the decision “crushing news”, while Téa Braun, the director of the Human Dignity Trust, a campaign group using litigation to fight anti-LGBT prejudice, said it was a huge setback for human rights in Kenya.

“All Kenyan citizens are guaranteed human dignity, equality before the law and freedom from discrimination under the 2010 constitution,” Braun said. “Yet in handing down this disappointing judgment, the court has ruled that a certain sector of society is undeserving of those rights.”

Homosexuality is illegal in most countries on the African continent. In several countries, gay people face life imprisonment or the death penalty.

“The ruling sends a dangerous signal to the other 72 countries where citizens are made ‘criminals’ simply because of their sexual orientation or gender identity,” Braun added.

LGBT activists and their supporters await the ruling outside court in Nairobi on Friday morning. Photograph: Khalil Senosi/AP

Hate crimes against gay people – including physical and sexual assault, blackmail and extortion – are common in Kenya, but most victims are too fearful to go to the police, rights groups say. Campaigners say the laws are also used daily to discriminate against LGBT people, making it harder for them to get a job or promotion, rent housing or access health and education services.

Kenya arrested 534 people for having same-sex relations between 2013 and 2017. According to petitioners against the law, there have been more than 1,500 attacks against LGBT Kenyans since 2014.

The court heard from expert witnesses who said there have long been established traditions of tolerance of same-sex relationships in Africa. It had been due to deliver its ruling in February, but postponed it until May.

Reform of the law was opposed by the Kenya Christian Professionals Forum, a coalition of Catholic, Protestant and Evangelical churches.

Gerald Walterfang, from the forum, said it was delighted with the ruling against a “destructive sexual lifestyle” and called the case “an attempt to sanitise what is illicit”.

A 2013 survey found that 90% of the population in Kenya did not think society should accept same-sex relationships. In several other African countries, levels of disapproval were even higher.

Last year President Uhuru Kenyatta told CNN that gay rights were “not of any major importance” in the country and that laws criminalising same-sex relations were supported by “99%” of the Kenyan people.

In neighbouring Tanzania, authorities in Dar es Salaam, the biggest city, have launched a series of crackdowns on gay people in recent years. In the most recent the city’s governor called on citizens to identify gay people so they could be arrested, forcing hundreds of people into hiding.



However there has been progress elsewhere, including Angola, which decriminalised gay sex in January. In March, the high court in Botswana heard a case brought by campaigners challenging the constitutionality of a law punishing same-sex relations.

“The judgment is very sad but I am genuinely happy the Kenyan LGBTI movement came this far,” said Bahiru Shewaye, founder of the Ethiopian LGBT advocacy and campaigning organisation House of Guramayle, on Friday .

“As I have said to my Kenyan rainbow family, they are visible and their existence is acknowledged. The fight is not over.”