State legalization of same-sex marriage appears to be linked to a decrease in adolescent suicide, based on a new analysis published today in JAMA Pediatrics. The results give more context to the potential effects of social policy on mental health.

The researchers found that suicide attempts by high school students decreased by 7 percent in states after they passed laws to legalize same-sex marriage, before the Supreme Court legalized it nationwide in 2015. Among LGB high school students, the decrease was especially concentrated, with suicide attempts falling by 14 percent.

But in states that did not legalize same-sex marriage, there was no change.

Suicide is the 10th-leading cause of death in the U.S. and the second for people aged 10 to 24. But young LGB people are particularly affected, attempting suicide at four times the rate of straight youth, according to the Trevor Project, an organization that works to prevent suicide among LGBT youth.

The study took place during a period where the suicide rate generally rose in the U.S., highlighting the fact that more intervention is still needed.

This new research “helps us better understand why we might see elevated rates of suicide attempts among LGBT adolescents,” Julia Raifman, the study leader and a postdoctoral fellow at the Johns Hopkins Bloomberg School of Public Health, said.

Raifman and her colleagues looked at 32 of the 35 states that legalized same-sex marriage between 2004 and 2015, comparing suicide rates in those states to suicide rates in states that did not legalize same-sex marriage.

They analyzed survey responses from 762,678 students who participated in the Centers for Disease Control and Prevention’s Youth Risk Behavior Surveillance System between 1999 — five years before Massachusetts became the first state to legalize same-sex marriage — and the end of 2015. The data was weighted to be representative of high school students in every state, Raifman said.

Raifman told the NewsHour she was interested in studying same-sex marriage laws “as a marker of equal rights in general,” adding that other laws that pertain to LGBT rights — such as employment and housing protections — still vary widely around the country.

The study noted that the laws themselves reflected larger social trends toward support for the LGBT community, a possible factor in the fall in suicide attempts. But Raifman said that the decrease was especially concentrated around the time that same-sex marriage laws passed.

While the study drew a correlation between lower suicide rates and same-sex marriage legalization, it did not explain a potential cause for the lowered rates. It is possible that the laws “communicated to young LGB populations that they were equal, and that improved their mental health,” Raifman said. It’s also possible that increased visibility for same-sex marriage, both in politics and media coverage, increased LGB adolescents’ sense of social support, she said.

The feelings of being accepted and connected to society have “a protective effect in relation to suicide risk, suicidal ideation and suicidal behaviors,” said Dr. Victor Schwartz, a chief medical officer of the JED Foundation who works to reduce youth suicide. Schwartz wasn’t involved in the study.

As a psychiatrist who has treated students at several colleges, Schwartz said he has seen the painful effects of stigma firsthand.

“It’s a real risk factor, a feeling that you’re at odds with your family or community,” Schwartz said. “It’s very painful, and can be very frightening. You feel like you’re going to be left out on your own.”

Discrimination is a suicide risk factor for any minority group, including LGB youth, Dr. Ken Duckworth, the medical director for the National Alliance of Mental Illness, wrote in an email to the NewsHour.

He noted that the study took place during a period where the suicide rate generally rose in the U.S., highlighting the fact that more intervention is still needed. “We need better ways to impact populations that are at high risk such as this one,” he wrote.

In the past, the denial of same-sex marriage has been motivated by false stereotypes of gay men and lesbians as unfit for marriage or parenthood, according to a 2006 paper by Dr. Gilbert Herdt, founder of the Department of Sexuality Studies at San Francisco State University, and Dr. Robert Kertzner, Associate Clinical Professor at the Columbia University Department of Psychiatry.

In the paper for Sexuality Research and Social Policy, Herdt and Kertzner argued that those societal attitudes added to a sense of stigma and social isolation for gay men and lesbians and detracted from their mental health. “Policymakers in the United States should be concerned about the impact the denial of marriage has on the mental health and wellbeing of gay men and lesbians,” they wrote.

Today, research is “showing positive health effects of social policies that affirm and protect the equality of the LGBT community, and those positive benefits extend beyond LGBT individuals to the general population,” Dr. Brian Mustanski, a professor at Northwestern University and Director of the Institute for Sexual and Gender Minority Health and Wellbeing, wrote in an email to the NewsHour.

One study, published in Pediatrics in 2011, showed that LGB youths were 20 percent more likely to attempt suicide if they were living in unsupportive environments.

Raifman said the study suggested a lot of ideas for further research on how different environments can add to, or detract from, the risk for suicide.

“Regardless of political views, I think everyone can agree that reducing adolescent suicide attempts is a good thing,” she said.