India's Supreme Court has ruled to decriminalise gay sex, in an historic and unanimous verdict handed down by a five-judge panel that will have a profound impact both here in India and across the world.

The courtroom in Delhi was overflowing with LGBT+ activists who have battled for 20 years for this moment, and a cheer erupted as word came from inside that consensual sex between adults of any gender was no longer deemed a crime.

Until now, gay sex had been punishable by up to 10 years in prison under Section 377 of the Indian constitution, a relic of the Victorian-era laws imposed by the British Empire. It outlawed sexual activities “against the order of nature” and was interpreted by police and courts as referring to homosexuality.

Celebrating under a sweltering sun on the lawns outside the courtroom, LGBT+ activists said they were finally free from a law that, though rarely enforced, was the foundation for systemic discrimination and harassment of gay Indians.

Reading out his judgment on the case, the Chief Justice of India Dipak Misra said interpreting Section 377 to criminalise gay sex was “irrational, arbitrary and indefensible”.

“Any consensual sexual relationship between two consenting adults – homosexuals, heterosexuals or lesbians – cannot be said to be unconstitutional,” Mr Misra said.

Scenes of celebration were broadcast on TV and social media from Mumbai, Chennai and other cities across India, as Mr Misra observed that members of the LGBT+ community “must have the same rights as any other citizen”.

Anjali Gopalan, the founder of the Naz Foundation charity that has been instrumental to the fight against Section 377, told The Independent outside court it was “wonderful news”.

“They have opened the door to discussing rights. They have apologised to the gay community, and they have said copies of the judgment will be handed to every police station. It is the best judgment we could have hoped for,” she said.

Security guards beat woman at LGBT+ event in China

Bismaya, an activist with the Delhi branch of Impulse, an LGBT+ advocacy group, told The Independent. “I’m so happy, it’s overwhelming. I cried when we heard the news.

“I’m gay and I’m not afraid of that. It’s something I used to say, but now for the first time I have the legal backing. Finally, the law is going to protect me.”

“It’s great for me but it’s also a great day for the whole of India. Acceptance in wider society will take time, because we cannot expect change overnight.

“It has been a battle for two decades for this judgment. If now we get full acceptance in a couple of years, that would be great.”

​The Indian government had left Thursday’s decision up to the Supreme Court, saying it would neither fight nor directly support the five lead petitioners asking for Section 377 to be reconsidered.

Legal experts interpreted that as implicit backing for the movement, which started in the courts in 2001 with a legal challenge to the Delhi High Court from Ms Gopalan’s Naz Foundation.

In 2009, the High Court declared the ban on gay sex to be unconstitutional. But that judgment was overturned by a small panel of the Supreme Court, which said amending or repealing the law should be left to Parliament.

“We have finally got justice,” said Ashok Row Kavi, LGBT+ rights activist and founder of Humsafar Trust, outside the court.

‘It’s great for me, but it’s also a great day for the whole of India’ – Bismaya, LGBT+ activist (Adam Withnall, The Independent)

The government had asked the Supreme Court to keep strictly to the issue of decriminalisation in its judgment, wary of opening up a whole new debate on the matter of equal marriage in what remains a very conservative society.

But activists and the petitioners themselves had asked the judges to go further. ”It is not only about decriminalising but recognising our fundamental rights,” said Akhilesh Godi, one of the petitioners in the case.

Today they celebrated a judgment which included not just decriminalisation and an apology, but also recommendations for workshops in schools and police stations across India to try and change public perceptions.

Bhuvan, an activist working to improve gay rights in the workplace, said the judges had been “beautiful”, adding there was still “a long journey ahead to social acceptance” for gay people across the country.

“We live in metropolises,” he said. “People in smaller cities might not even hear about this, likewise people who are not in the upper castes. It needs to percolate down to the ground – but I think all the activists here are pretty gung ho about taking this forward.”

When he came out in 2012, Bhuvan said, he did not feel India was a country “where I can really be myself”.

“Now the day has come, 6 September 2018, when finally we are able to breathe free,” he told The Independent. ”We are first-class citizens of our country, not ‘illegal’ in the eyes of the law.

“It’s better late than never.”

India was just one of a number of Commonwealth countries that still used colonial-era laws to prosecute and punish gay people. Mukul Rohatgi, the former attorney general of India who led the case on behalf of the petitioners, asked why India in the 21st century continued “to tolerate Victorian models of behaviour from the 1860s”.

Paul Dillane, director of the international LGBT+ rights charity The Kaleidoscope Trust, said the ruling had “truly global repercussions” for the 70 other countries in the world where laws continue to criminalise consensual same-sex acts. Experts say India will now be used as a case study in legal battles brought by LGBT+ activists in other places.