U.S. counties that weathered the closure of auto assembly factories saw a spike in opioid overdoses in the five years after the plants were shut down, a new study from the University of Pennsylvania has found.

The findings are a window into how economic instability can drive a public health crisis, said lead author Atheendar Venkataramani, an assistant professor of health policy and medicine at Penn’s Perelman School of Medicine.

Factory closures “are a culturally significant shock to the economy, which has a real effect on depressing economic opportunities for people over a long period of time,” he said. “When there is a contraction of economic activities — when people feel the economy and society is shifting in a way that it reduces their chances of upward mobility and happiness, you see this despair set in.”

The study, published in JAMA Internal Medicine, looked at overdose mortality rates among 18- to 65-year-olds in 112 manufacturing counties — places where most workers are in the manufacturing industry, primarily in the Midwest and South — that were home to at least one auto assembly plant.

Between 1999 and 2016, overdose rates in counties that lost their auto plants were 85% higher than in counties that retained their factories.

In their analysis, Venkataramani and his co-authors controlled for other factors that might have contributed to a rise in overdose deaths, such as national shifts in the availability of opioids and the onset of the Great Recession.

“We can’t definitively prove causality. I can’t be 100% confident that we ruled out all the different things that might have contributed to the opioid crisis in these areas,” he said. But, he said, counties that lost plants and counties that did not had relatively similar overdose rates before the factories closed.

Overdoses began to spike more dramatically in counties that lost plants only after the factories closed, he said.

It’s a pattern that Venkataramani has seen replicated in several other studies on different social phenomena: When people believe that they have less upward mobility or opportunity, their mental and physical health suffers. For example, another study Venkataramani worked on found that, in states that banned colleges from instituting affirmative action policies, black, Hispanic, and Native American high schoolers began to smoke more after the ban went into effect.

“People’s motivation, whether it’s from information about the future or policies that shift how people think about the future, has large effects on health behaviors and mental health,” he said.

The health-care system rarely takes such factors into account when designing interventions for people with addiction, said Philippe Bourgois, a professor of anthropology at UCLA and a former Penn professor who studied the drug trade in Philadelphia for years.

On the ground in Kensington — which lost thousands of manufacturing jobs as the city’s industrial base declined — he spoke to residents about the demoralization they felt as jobs became less stable and day-to-day survival became less assured.

“It’s the failure of our public health system to recognize how crucial social structural factors are,” he said. “All our drug treatment programs, and all the ways money gets invested, tend to focus on the psychological, individual decision-making process. In fact, evidence suggests that [we should] create interventions that would provide things like jobs for people in drug treatment programs — as opposed to a pep talk.”