Data

Legal status of same-sex sexual acts

See all data and research on:

About this data

Legal status of same-sex sexual acts
Legal status of consensual homosexual acts among adults in public. The categories are "Legal" and "Illegal".
Source
Mignot (2025)with major processing by Our World in Data
Last updated
July 9, 2025
Next expected update
July 2026
Date range
1760–2025

Sources and processing

Mignot – Homosexuality criminalization data from Mignot

Most of the world’s countries have at some point prohibited homosexual acts among consenting adults in private. Where, when and how were homosexual relations decriminalized in the world since the Age of Enlightenment? Historical data on the legality of homosexual acts and on population numbers in 203 present-day countries allows us to compute the annual share of the world population who live in a country where homosexual acts are legal (vs. a criminal offence), since 1760. Although France became the first country to decriminalize homosexual acts (1791) and inspired the first wave of decriminalization in Western Europe, Latin America and the Ottoman Empire, in the 19th century fewer than 25% of humans lived in a country which did not criminalize homosexual relations. The second wave of decriminalization, which was based on increasingly liberal public opinions regarding acts among consenting adults, started in Western Europe and North America in the 1960s and then spread to Oceania, Eastern Europe and finally Asia. In 2020, more than 75% of humans live in a country which no longer criminalizes homosexual relations. Liberalization has been uneven, though: homosexual acts are still a crime for most of the inhabitants in Africa and in Muslim-majority countries, and they are especially harshly punished in a few Islamic law states and sub-state entities. As the countries which criminalize homosexual acts today will grow demographically relatively fast in the coming decades, the share of humans who are legally free to engage in homosexual acts will likely decrease, except if a sufficiently large number of sufficiently populated criminalizing countries decriminalize soon.

Retrieved on
July 9, 2025
Citation
This is the citation of the original data obtained from the source, prior to any processing or adaptation by Our World in Data. To cite data downloaded from this page, please use the suggested citation given in Reuse This Work below.
Jean-François Mignot (2022). Decriminalizing Homosexuality: A Global Overview Since the 18th Century. Annales de démographie historique, In press, 1. Appendix: Table 1. (Updated July 2025).

Most of the world’s countries have at some point prohibited homosexual acts among consenting adults in private. Where, when and how were homosexual relations decriminalized in the world since the Age of Enlightenment? Historical data on the legality of homosexual acts and on population numbers in 203 present-day countries allows us to compute the annual share of the world population who live in a country where homosexual acts are legal (vs. a criminal offence), since 1760. Although France became the first country to decriminalize homosexual acts (1791) and inspired the first wave of decriminalization in Western Europe, Latin America and the Ottoman Empire, in the 19th century fewer than 25% of humans lived in a country which did not criminalize homosexual relations. The second wave of decriminalization, which was based on increasingly liberal public opinions regarding acts among consenting adults, started in Western Europe and North America in the 1960s and then spread to Oceania, Eastern Europe and finally Asia. In 2020, more than 75% of humans live in a country which no longer criminalizes homosexual relations. Liberalization has been uneven, though: homosexual acts are still a crime for most of the inhabitants in Africa and in Muslim-majority countries, and they are especially harshly punished in a few Islamic law states and sub-state entities. As the countries which criminalize homosexual acts today will grow demographically relatively fast in the coming decades, the share of humans who are legally free to engage in homosexual acts will likely decrease, except if a sufficiently large number of sufficiently populated criminalizing countries decriminalize soon.

Retrieved on
July 9, 2025
Citation
This is the citation of the original data obtained from the source, prior to any processing or adaptation by Our World in Data. To cite data downloaded from this page, please use the suggested citation given in Reuse This Work below.
Jean-François Mignot (2022). Decriminalizing Homosexuality: A Global Overview Since the 18th Century. Annales de démographie historique, In press, 1. Appendix: Table 1. (Updated July 2025).

All data and visualizations on Our World in Data rely on data sourced from one or several original data providers. Preparing this original data involves several processing steps. Depending on the data, this can include standardizing country names and world region definitions, converting units, calculating derived indicators such as per capita measures, as well as adding or adapting metadata such as the name or the description given to an indicator.

At the link below you can find a detailed description of the structure of our data pipeline, including links to all the code used to prepare data across Our World in Data.

Read about our data pipeline
Notes on our processing step for this indicator

From the original table, we constructed a new dataset with data for all countries between 1760 and 2025.

For countries where criminalization was implemented at different points in time across their regions, we considered the earliest year of the change as the year of criminalization. This is the case for the United States (1610-1948).

Conversely, for countries where decriminalization was implemented at different points in time across their regions, we considered the latest year of the change as the year of decriminalization. This is the case for Australia (1975-1997), Bosnia and Herzegovina (1998-2001), United Kingdom (1967-1982), and United States (1962-2003).

We consider the year of the last decriminalization of homosexuality in Germany to be 1969, the year it was decriminalized in West Germany. East Germany did it in 1968.

We modified the homosexuality status for Russia, Armenia, Azerbaijan, Estonia, Georgia, Kazakhstan, Kyrgyzstan, Latvia, Lithuania, Moldova, Tajikistan, Turkmenistan, and Uzbekistan before 1832 to "Legal" to reflect what it is mentioned on page 8 of the original paper ([the Russian Empire] have not criminalized these practices since at least the 18th century).

How to cite this page

To cite this page overall, including any descriptions, FAQs or explanations of the data authored by Our World in Data, please use the following citation:

“Data Page: Legal status of same-sex sexual acts”, part of the following publication: Bastian Herre and Pablo Arriagada (2023) - “LGBT+ Rights”. Data adapted from Mignot. Retrieved from https://archive.ourworldindata.org/20260304-094028/grapher/legal-status-of-same-sex-sexual-acts.html [online resource] (archived on March 4, 2026).

How to cite this data

In-line citationIf you have limited space (e.g. in data visualizations), you can use this abbreviated in-line citation:

Mignot (2025) – with major processing by Our World in Data

Full citation

Mignot (2025) – with major processing by Our World in Data. “Legal status of same-sex sexual acts” [dataset]. Mignot, “Homosexuality criminalization data from Mignot” [original data]. Retrieved April 1, 2026 from https://archive.ourworldindata.org/20260304-094028/grapher/legal-status-of-same-sex-sexual-acts.html (archived on March 4, 2026).

Quick download

Download the data shown in this chart as a ZIP file containing a CSV file, metadata in JSON format, and a README. The CSV file can be opened in Excel, Google Sheets, and other data analysis tools.

Data API

Use these URLs to programmatically access this chart's data and configure your requests with the options below. Our documentation provides more information on how to use the API, and you can find a few code examples below.

Data URL (CSV format)
https://ourworldindata.org/grapher/legal-status-of-same-sex-sexual-acts.csv?v=1&csvType=full&useColumnShortNames=false
Metadata URL (JSON format)
https://ourworldindata.org/grapher/legal-status-of-same-sex-sexual-acts.metadata.json?v=1&csvType=full&useColumnShortNames=false

Code examples

Examples of how to load this data into different data analysis tools.

Excel / Google Sheets
=IMPORTDATA("https://ourworldindata.org/grapher/legal-status-of-same-sex-sexual-acts.csv?v=1&csvType=full&useColumnShortNames=false")
Python with Pandas
import pandas as pd
import requests

# Fetch the data.
df = pd.read_csv("https://ourworldindata.org/grapher/legal-status-of-same-sex-sexual-acts.csv?v=1&csvType=full&useColumnShortNames=false", storage_options = {'User-Agent': 'Our World In Data data fetch/1.0'})

# Fetch the metadata
metadata = requests.get("https://ourworldindata.org/grapher/legal-status-of-same-sex-sexual-acts.metadata.json?v=1&csvType=full&useColumnShortNames=false").json()
R
library(jsonlite)

# Fetch the data
df <- read.csv("https://ourworldindata.org/grapher/legal-status-of-same-sex-sexual-acts.csv?v=1&csvType=full&useColumnShortNames=false")

# Fetch the metadata
metadata <- fromJSON("https://ourworldindata.org/grapher/legal-status-of-same-sex-sexual-acts.metadata.json?v=1&csvType=full&useColumnShortNames=false")
Stata
import delimited "https://ourworldindata.org/grapher/legal-status-of-same-sex-sexual-acts.csv?v=1&csvType=full&useColumnShortNames=false", encoding("utf-8") clear