Section 377 of the Indian Penal Code is a section of the Indian Penal Code introduced in 1864 during the British rule of India. Modelled on the Buggery Act of 1533, it is used to criminalize sexual activities "against the order of nature". On 6 September 2018, the Supreme Court of India ruled that the application of Section 377 to consensual homosexual sex between adults was unconstitutional, "irrational, indefensible and manifestly arbitrary", but that Section 377 remains in force relating to sex with minors, non-consensual sexual acts, and bestiality.
Portions of the section were first struck down as unconstitutional with respect to gay sex by the Delhi High Court in July 2009. That judgement was overturned by the Supreme Court of India (SC) on 11 December 2013 in Suresh Kumar Koushal vs. Naz Foundation. The Court held that amending or repealing section 377 should be a matter left to Parliament, not the judiciary. On 6 February 2016, a three-member bench of the Court reviewed curative petitions submitted by the Naz Foundation and others, and decided that they would be reviewed by a five-member constitutional bench.
On 24 August 2017, the Supreme Court upheld the right to privacy as a fundamental right under the Constitution in the landmark Puttuswamy judgement. The Court also called for equality and condemned discrimination, stated that the protection of sexual orientation lies at the core of the fundamental rights and that the rights of the LGBT population are real and founded on constitutional doctrine. This judgement was believed to imply the unconstitutionality of section 377.
In January 2018, the Supreme Court agreed to hear a petition to revisit the 2013 Naz Foundation judgment. On 6 September 2018, the Court ruled unanimously in Navtej Singh Johar v. Union of India that Section 377 was unconstitutional "in so far as it criminalises consensual sexual conduct between adults of the same sex".
377. Unnatural offences: Whoever voluntarily has carnal intercourse against the order of nature with any man, woman or animal shall be punished with imprisonment for life, or with imprisonment of either description for a term which may extend to ten years, and shall also be liable to fine.
In 2008 Additional Solicitor General PP Malhotra said: "Homosexuality is a social vice and the state has the power to contain it. [Decriminalising homosexuality] may create [a] breach of peace. If it is allowed then [the] evil of AIDS and HIV would further spread and harm the people. It would lead to a big health hazard and degrade moral values of society." This view was shared by the Home Ministry.
11 December 2013 judgement of the Supreme Court, upholding Section 377 was met with support from religious leaders. The Daily News and Analysis called it "the univocal unity of religious leaders in expressing their homophobic attitude. Usually divisive and almost always seen tearing down each other’s religious beliefs, leaders across sections came forward in decrying homosexuality and expressing their solidarity with the judgement." The Daily News and Analysis article added that Baba Ramdev, India's well-known yoga guru, after praying that journalists not "turn homosexual", stated he could "cure" homosexuality through yoga and called it "a bad addiction". The Vishwa Hindu Parishad's vice-president Om Prakash Singhal said, "This is a right decision, we welcome it. Homosexuality is against Indian culture, against nature and against science. We are regressing, going back to when we were almost like animals. The SC had protected our culture." The article states that Singhal further went to dismiss HIV/AIDS concerns within the LGBT community as, "It is understood that when you try to suppress one anomaly, there will be a break-out of a few more." (Traditionally, Indian culture, or at least Hinduism, has been more ambivalent about homosexuality than Singhal suggests.) Maulana Madni of the Jamiat Ulema echoes this in the article, stating that "Homosexuality is a crime according to scriptures and is unnatural. People cannot consider themselves to be exclusive of a society... In a society, a family is made up of a man and a woman, not a woman and a woman, or a man and a man." Rabbi Ezekiel Issac Malekar, honorary secretary of the Judah Hyam Synagogue, in upholding the judgment was also quoted as saying "In Judaism, our scriptures do not permit homosexuality." Reverend Paul Swarup of the Cathedral Church of the Redemption in Delhi in stating his views on what he believes to be the unnaturalness of homosexuality, stated "Spiritually, human sexual relations are identified as those shared by a man and a woman. The Supreme Court’s view is an endorsement of our scriptures."
The Ministry of Health and Family Welfare opposed the upholding of Section 377, stating that it would hinder anti-HIV/AIDS efforts. According to the NCRB, in 2015, 1,491 people were arrested under Section 377, including 207 minors (14%) and 16 women. Human Rights Watch also argues that the law has been used to harass HIV/AIDS prevention efforts, as well as sex workers, homosexuals, and other groups at risk of the disease, even though those found guilty of extortion in relation to accusations that relate to Section 377 may face a life sentence under a special provision of Section 389 of the IPC. The People's Union for Civil Liberties has published two reports of the rights violations faced by sexual minorities and, in particular, transsexuals in India.
In 2006 it came under criticism from 100 Indian literary figures, most prominently Vikram Seth. The law subsequently came in for criticism from several ministers, most prominently Anbumani Ramadoss and Oscar Fernandes. In 2008, a judge of the Bombay High Court also called for the scrapping of the law.
The United Nations said that the ban violates international law. United Nations human rights chief Navi Pillay stated that "Criminalising private, consensual same-sex sexual conduct violates the rights to privacy and to non-discrimination enshrined in the International Covenant on Civil and Political Rights, which India has ratified", and that the decision "represents a significant step backwards for India and a blow for human rights.", voicing hope that the Court might exercise its review procedure.
Rajnath Singh, a member of the ruling party BJP and the Home Minister, is on record shortly after the law was re-instated in 2013, claiming that his party is "unambiguously" in favour of the law, also claiming that "We will state (at an all-party meeting if it is called) that we support Section 377 because we believe that homosexuality is an unnatural act and cannot be supported.” Yogi Adityanath, BJP MP, Chief minister of Uttar Pradesh, endorsed Radev's comments, saying he welcomes the verdict and will "oppose any move to decriminalise homosexuality."
The Samajwadi Party made it clear that it will oppose any amendments to the section if it comes in Parliament for discussion, calling homosexuality "unethical and immoral." Ram Gopal Yadav stated that they support the Supreme Court decision as "It is completely against the culture of our nation."
Finance Minister and BJP member Arun Jaitley has a different view from Rajnath Singh, saying that "Supreme Court should not have reversed the Delhi High Court order which de-criminalised consensual sex between gay adults" and "When millions of people the world over are having alternative sexual preferences, it is too late in the day to propound the view that they should be jailed.". BJP spokesperson Shaina NC said her party supports decriminalisation of homosexuality. "We are for decriminalising homosexuality. That is the progressive way forward."
In December 2013, Indian National Congress vice-president Rahul Gandhi came out in support of LGBT rights and said that "every individual had the right to choose". He also said "These are personal choices. This country is known for its freedom, freedom of expression. So let that be. I hope that Parliament will address the issue and uphold the constitutional guarantee of life and liberty to all citizens of India, including those directly affected by the judgement", he said. The LGBT rights movement in India was also part of the election manifesto of the Congress for the 2014 general elections. Senior Congress leader and former Finance Minister P Chidambaram expressed his disappointment, saying we have gone back in time and must quickly reverse the judgement. He also said that "Section 377, in my view, was rightly struck down or read down by the Delhi High Court judgement by Justice AP Shah."
After the 2013 verdict, the Aam Aadmi Party put on their website:
The Aam Aadmi party is disappointed with the judgment of the Supreme Court upholding the Section 377 of the IPC and reversing the landmark judgment of the Delhi High Court on the subject. The Supreme Court judgment thus criminalises the personal behaviour of consenting adults. All those who are born with or choose a different sexual orientation would thus be placed at the mercy of the police. This not only violates the human rights of such individuals, but goes against the liberal values of our Constitution, and the spirit of our times. Aam Aadmi Party hopes and expects that the Supreme Court will review this judgment and that the Parliament will also step in to repeal this archaic law.
Shivanand Tiwari, leader of Janata Dal United, did not support the Supreme Court decision, calling homosexuality practical and constitutional. He added that "This happens in society and if people believe it is natural for them, why is the Supreme Court trying to stop them?"
The movement to repeal Section 377 was initiated by AIDS Bhedbhav Virodhi Andolan in 1991. Their historic publication Less than Gay: A Citizen's Report, spelt out the problems with 377 and asked for its repeal. A 1996 article in Economic and Political Weekly by Vimal Balasubrahmanyan titled 'Gay Rights In India' chronicles this early history. As the case prolonged over the years, it was revived in the next decade, led by the Naz Foundation (India) Trust, an activist group, which filed a public interest litigation in the Delhi High Court in 2001, seeking legalisation of homosexual intercourse between consenting adults. The Naz Foundation worked with a legal team from the Lawyers Collective to engage in court. In 2003, the Delhi High Court refused to consider a petition regarding the legality of the law, saying that the petitioners, had no locus standi in the matter. Since nobody had been prosecuted in the recent past under this section it seemed unlikely that the section would be struck down as illegal by the Delhi High Court in the absence of a petitioner with standing. Naz Foundation appealed to the Supreme Court against the decision of the High Court to dismiss the petition on technical grounds. The Supreme Court decided that Naz Foundation had the standing to file a PIL in this case and sent the case back to the Delhi High Court to reconsider it on merit. Subsequently, there was a significant intervention in the case by a Delhi-based coalition of LGBT, women's and human rights activists called 'Voices Against 377', which supported the demand to 'read down' section 377 to exclude adult consensual sex from within its purview.
There was support from others like Sunil Mehra, a notable journalist. He was in a committed relationship with Karan Johar (a renowned Indian movie director and producer) and drew from his personal experiences while protesting. Ritu Dalmia also demonstrated keen activism. Aman Nath, a writer, historian, and hotelier, also fought for the decriminalisation of Section 377. He had a relationship with Francis Wacziarg for 23 years until Wacziarg passed away. Ayesha Kapur became successful within a decade of working in a nascent e-commerce sector. However, she left her job because she was afraid of people finding out about her sexuality. Over time, she gained the courage to come out and challenge Section 377. 
In May 2008, the case came up for hearing in the Delhi High Court, but the Government was undecided on its position, with The Ministry of Home Affairs maintaining a contradictory position to that of The Ministry of Health on the issue of enforcement of Section 377 with respect to homosexuality. On 7 November 2008, the seven-year-old petition finished hearings. The Indian Health Ministry supported this petition, while the Home Ministry opposed such a move. On 12 June 2009, India's new law minister Veerappa Moily agreed that Section 377 might be outdated.
Eventually, in a historic judgement delivered on 2 July 2009, Delhi High Court overturned the 150-year-old section, legalising consensual homosexual activities between adults. The essence of the section goes against the fundamental right of human citizens, stated the high court while striking it down. In a 105-page judgement, a bench of Chief Justice Ajit Prakash Shah and Justice S Muralidhar said that if not amended, section 377 of the IPC would violate Article 14 of the Indian constitution, which states that every citizen has equal opportunity of life and is equal before law.
The two-judge bench went on to hold that:
|“||If there is one constitutional tenet that can be said to be underlying theme of the Indian Constitution, it is that of 'inclusiveness'. This Court believes that Indian Constitution reflects this value deeply ingrained in Indian society, nurtured over several generations. The inclusiveness that Indian society traditionally displayed, literally in every aspect of life, is manifest in recognising a role in society for everyone. Those perceived by the majority as 'deviants' or 'different' are not on that score excluded or ostracised.
Where society can display inclusiveness and understanding, such persons can be assured of a life of dignity and non-discrimination. This was the 'spirit behind the Resolution' of which Nehru spoke so passionately. In our view, Indian Constitutional law does not permit the statutory criminal law to be held captive by the popular misconceptions of who the LGBTs are. It cannot be forgotten that discrimination is antithesis of equality and that it is the recognition of equality which will foster the dignity of every individual.
The court stated that the judgement would hold until Parliament chose to amend the law. However, the judgement keeps intact the provisions of Section 377 insofar as it applies to non-consensual non-vaginal intercourse and intercourse with minors.
A batch of appeals were filed with the Supreme Court, challenging the Delhi High Court judgment. On 27 March 2012, the Supreme Court reserved verdict on these. After initially opposing the judgement, the Attorney General G. E. Vahanvati decided not to file any appeal against the Delhi High Court's verdict, stating, "insofar as [Section 377 of the Indian Penal Code] criminalises consensual sexual acts of adults in private [before it was struck down by the High Court] was imposed upon Indian society due to the moral views of the British rulers."
On 18 December 2015, Lok Sabha member Shashi Tharoor of the Indian National Congress, whose leaders Sonia Gandhi and Rahul Gandhi had earlier expressed support for LGBT Rights, introduced a private member's bill to replace Section 377 in the Indian Penal Code and decriminalize consensual same-sex relations. The bill was defeated in first reading, 71–24. For his part, Tharoor expressed surprise at the bill's rejection at this early stage. He said that he did not have time to rally support and that he will attempt to reintroduce the bill.
In March 2016, Tharoor tried to reintroduce the private member's bill to decriminalize homosexuality, but was voted down for the second time.
On 2 February 2016, the final hearing of the curative petition submitted by the Naz Foundation and others came for hearing in the Supreme Court. The three-member bench headed by the Chief Justice of India T. S. Thakur said that all the 8 curative petitions submitted will be reviewed afresh by a five-member constitutional bench.
On 24 August 2017, the Supreme Court of India held that the Right to Privacy is a fundamental right protected under Article 21 and Part III of the Indian Constitution. The judgement mentioned Section 377 as a "discordant note which directly bears upon the evolution of the constitutional jurisprudence on the right to privacy." In the judgement delivered by the 9-judge bench, Justice Chandrachud (who authored for Justices Khehar, Agarwal, Abdul Nazeer and himself), held that the rationale behind the Suresh Koushal (2013) Judgement is incorrect, and the judges clearly expressed their disagreement with it. Justice Kaul agreed with Justice Chandrachud's view that the right of privacy cannot be denied, even if there is a minuscule fraction of the population which is affected. He further went on to state that the majoritarian concept does not apply to Constitutional rights and the courts are often called upon to take what may be categorized as a non-majoritarian view, in the check and balance of power envisaged under the Constitution of India.
Sexual orientation is an essential attribute of privacy. Discrimination against an individual on the basis of sexual orientation is deeply offensive to the dignity and self-worth of the individual. Equality demands that the sexual orientation of each individual in society must be protected on an even platform. The right to privacy and the protection of sexual orientation lie at the core of the fundamental rights guaranteed by Articles 14, 15 and 21 of the Constitution.
...Their rights are not "so-called" but are real rights founded on sound constitutional doctrine. They inhere in the right to life. They dwell in privacy and dignity. They constitute the essence of liberty and freedom. Sexual orientation is an essential component of identity. Equal protection demands protection of the identity of every individual without discrimination.
However, as the curative petition (challenging Section 377) is currently sub-judice, the judges authored that they would leave the constitutional validity to be decided in an appropriate proceeding. Many legal experts have suggested that with this judgement, the judges have invalidated the reasoning behind the 2013 Judgement, thus laying the ground-work for Section 377 to be read down and the restoration of the 2009 Judgement of the High Court, thereby decriminalizing homosexual sex.
In 2018, the five-judge constitutional bench of the Supreme Court consisting of chief justice Dipak Misra and justices Dhananjaya Y. Chandrachud, Ajay Manikrao Khanwilkar, Indu Malhotra, and Rohinton Fali Nariman started hearing the challenge to constitutionality of Section 377. The Union Government did not take a position on the issue and left it to the "wisdom of the court" to decide on Section 377. The petitioners invoked the right to sexual privacy, dignity, right against discrimination and freedom of expression to argue against the constitutionality of Section 377.
After hearing the petitioners' plea for four days, the court reserved its verdict on 17 July 2018. The bench pronounced its verdict on 6 September 2018. Announcing the verdict, the court reversed its own 2013 judgement of restoring Section 377 by stating that using the section of the IPC to victimize homosexuals was unconstitutional, and henceforth, a criminal act. In its ruling, the Supreme Court stated that consensual sexual acts between adults cannot be a crime, deeming the prior law "irrational, arbitrary and incomprehensible."
The judgement also draws parallels to the Privy Council’s 1929 verdict in Edwards vs Canada (AG) that allowed for Women to sit in the Senate of Canada. Both cases are imperative to the question of full legal personage of the two marginalized sections of society, namely gender minority (women) and sexual minority (LGBTQIA).  Section 377 of the Indian Penal Code – significantly reduced personhood and liberties of LGBTQ citizens as they were denounced of their right to pursue consensual intimate relations, sexual expression and choice, which is currently reinforced by the Right to Privacy. The judgement further stands as an example for the court's capacity to counteract societal exclusion and marginalization of the community by upholding Articles 14, 15, 19 and 21 of the Constitution of India which promises liberty of thought and expression, equality of status and opportunity and fraternity assuring the dignity of the individual. In doing so, the petitioners, namely, Navtej Singh Johar, Sunil Mehra, Ritu Dalmia, Aman Nath and Keshav Suri – have become India’s ‘Valiant Five’.
Consensual adult gay sex is not a crime and article 14 and 21 of Indian Constitution contradict the present view of Section 377.