Donna Dibo is that rare thing: a lucky opioid addict. Lucky in that she got into so much trouble with the police that the US justice system stepped in to help her get clean. The tall, blonde mother of five has a tattoo of her husband's name peeking out of the neck of her grey cardigan. She has the voice of a life hard-lived, and a new job as a welder, making railcar components in Youngstown, Ohio, an epicenter of America's opioid crisis.

She is also a proud graduate of Mahoning County drug court, one of the most successful of a national network of courts aimed at helping addicts to get clean, get their families, jobs and lives back — and to dismiss or expunge their criminal records.

Dibo's is a fragile, upbeat tale, easily drowned out by the slew of headlines about US addiction. The bad news is undeniable: in 2017, drug overdoses, many from opioids, killed about 72,000 Americans — more than died in the entire Vietnam war, and more than the peak number of annual deaths from car crashes, Aids or guns.

Visit any courtroom in America — from rural Ohio to urban Chicago — and it's easy to count the costs of the crisis, in the currency of broken families, ruined homes and childhoods doomed by adult drug abuse.

The economic cost has been crippling too: opioids have robbed the American workforce of its biggest chunk of labor since the Spanish flu epidemic in the early 20th century, some analysts say. But, increasingly, a number of specialist courts are also counting success stories: families reunited, jobs regained, proof that there can be a life after opioids. The truth is that sometimes addicts do recover — and one of the best ways to do so, say addiction experts, is to end up in drug court.

The US's first drug court was established in 1989 in Miami in the wake of the crack epidemic that saw inner cities struggle with substance abuse and drug-related crimes. Today there are more than 3,000 of these courts nationwide.

Treating addiction as a disease, rather than a crime, they offer non-violent offenders the chance to avoid prison time by committing to an intensive, judicially supervised program of substance-abuse rehabilitation, random drug testing, regular court appearances and frequent mandatory attendance at "positive peer support" meetings, usually those of 12-step recovery groups.

"The number of drug courts has increased dramatically over time," says Shannon Carey of NPC research, an independent private research company that has studied the phenomenon. She says drug courts serve about 120,000 people in the US every year, and that more than a million people have "graduated" — the term used for successful completion of a drug court program — since the courts were invented.

"Catching these charges was the best thing that ever happened to me," says a trim man with a shaved head, a biker beard and a light in his eyes, as he stands up in Courtroom 4 of the Mahoning County courthouse for his mandatory appearance. Like everyone else there on this blizzardy day, this individual is an addict who could have faced years in jail if he had not signed up for the county's rigorous one-year-plus drug court program.

He proudly tells the court that he has attended 80 meetings of a 12-step program in his first 43 days, fingering a signed meeting log that is nearly coming apart at the seams from frequent use. Every addict present — each of whom could have used snow-clogged roads as an excuse not to come but did not — must stand up before the judge to report on progress. Most are white, some have the sallow, ravaged complexion of habitual drug use, and all sit slumped and glum awaiting their turn.

But then, in a swirl of black robes, the boyish figure of Judge Jack Durkin, 60, bounds on to the bench, and starts peppering them with questions about how life is treating them. And they perk up. "How's the car running, how's it doing in all this snow?" he asks an offender whose dyed-pink hair is fading to anaemic orange, as she announces that this is her 90th day of recovery. That's a significant milestone, so the judge prods her to turn around and announce it to the courtroom audience, which explodes in applause.

"What step are you working on?" he asks another, "and did you start that job at the dealership?" "I hear there's somebody new in your life," he says sternly to a woman who has lost custody of her children. "I don't want you to get distracted from what you need to do to recover," he chides, dispensing relationship advice to her before turning his attention to a convict with chained hands and feet, clad in an orange jumpsuit.

The atmosphere is not unlike a 12-step recovery meeting, what with all the applause and the day-counting; but this is no church basement serving bad coffee with non-dairy creamer. The architecture of Courtroom 4 evokes the gilded age of Youngstown, when it was known as Steel Town USA. The coffered ceiling is gilt-edged, and the walls are adorned with mahogany and murals, including one where the chiefs of American Indian tribes celebrate victory over the British in 1755.

The city that steel built is also the city that steel ruined: today's Youngstown is less a symbol of industrial prowess than an icon of American loss; a town that has shed people and purpose in the long decline of the US Rust Belt. Today it anchors a region with among the worst opioid addiction problems in the US: a place where the disappearance of tens of thousands of jobs since the late 1970s has brought despair. This has led to drugs, and these drugs have led people to drop out permanently from the labor force. A downward spiral fuelled by opioids.

"We have less than a 9 percent recidivism rate among those [57 percent] who complete the drug court program," says Durkin, one of America's most experienced practitioners of what is known as "therapeutic jurisprudence": using the law to help treat people. That 9 percent rate applies to the 642 people who have "graduated" from his drug court since it opened in the late 1990s, out of the 1,127 who tried. US recidivism rates outside drug court are much higher: about two-thirds offend again within three years of their release, and three-quarters after five years.

Durkin has been on the bench since 1997, plenty of time to despair about how little American justice normally does to right the wrongs of US society. Yet he has spent those 20 years proving the proposition that habitual addicts and offenders can become clean, upstanding citizens, given the right judicial conditions. Those who enter his courtroom are invited to disable their cynicism along with their cellphones; this is a place of hope, not despair.

"The relationship with the judge is key," he says, echoing the conclusions of experts who have studied drug courts nationwide. But he is the first to point out that he couldn't do it without the dedicated team of true believers who support his court, from sympathetic prosecutors to tough-love probation officers, non-judgmental recovery coaches and the passionate, energetic court co-ordinator Amy Klumpp.

The team is on call around the clock to help addicts get clean but also, crucially, to use the might of the state and the money of local charities and government to remove the obstacles that kept them stuck in addiction in the first place, such as problems with jobs, housing and family.

Most drug courts receive a combination of funding from local, county and state governments, with some also getting federal funding. Many programs rely on money from non-profits to pay for addiction treatment, and for the job searches and training that are often critical to keeping participants clean in the long run. Those trying to get clean also help to finance it: in the Youngstown court, participants pay $25 a month, while some staff donate their time. Durkin, for example, receives no extra compensation for running the drug court.

The stakes could not be higher. Ohio, where Youngstown is located, had the second highest rate of drug overdose deaths in the US in 2016, after West Virginia. According to a recent study by Ohio State University, the state's drug overdose death rate grew ninefold between 1999 and 2016, three times as fast as the national growth rate. In 2015, the opioid crisis cost Ohio as much as total annual state spending on public education for five- to 18-year-olds, the study found.

The Ohio State researchers believe opioid abuse could also account for one-third to half of the drop in the state's labor force from six million in 2007 to 5.7 million in 2016. And though opioid deaths initially hit mostly middle-aged workers, they have since trended younger, with deaths concentrated in prime working years. These statistics have grim implications in a state where the tight labor market is beginning to make it harder for companies to hire enough workers to meet demand in a booming US economy.

"This is the economic story of the year. Maybe it's the story of the decade," says Jeff Korzenik, chief investment strategist at Fifth Third Bank and an expert on the Midwest economy. "You'd have to go back to the great influenza epidemic of 1918 to find a comparable percentage of the workforce impacted by a health issue… The opioid crisis crosses so many socio-economic lines that almost anyone, no matter what their station in life, knows someone that has been touched by this."

"About 15 years ago, I was in a bad car accident and I was prescribed pain pills," says Donna Dibo. She has just graduated after 15 months in Mahoning County drug court — and had her felony convictions sealed as a result — and she is telling me the all-too-familiar story of how this happened to her. "I went for years of physical therapy for my back, my doctor was pretty easy — and we addicts learn how to say things, that's the addictive behavior. So I would ask and he would up my script — first it was Vicodin and Percocet, but later it was Roxys and Oxys [Roxicodone and Oxycodone] — then they became very hard to find, I was buying them on the streets. Then I couldn't find them, I was sick for a day and a half for not having anything, and that's how I got on heroin."

Relaxing on the steps outside the elegant marble halls of the courthouse, she enjoys a smoke and a sense of achievement. "I had warrants out for me, I was running for about two and a half years, then I got caught for felony crack possession. Drug court takes it away as if it never happened," she marvels.

This wasn't her first attempt to get clean: she has been "in and out of the rooms [12-step recovery meetings] for eight years". "I went to rehab several times but it didn't work," she tells the court as she collects her certificate of drug court graduation. Judge Durkin's team made all the difference. "None of these people ever gave up on me, even when I gave up on myself," says the stern-faced 37-year-old, whose children and stepchildren range in age from 10 to 24, before burying her statuesque frame in a bear hug from the diminutive figure of the judge who helped save her.

"Drug court is more hands-on [than rehab]," she later explains. "You have so many members on your team that reach out to you day and night, there's always someone there. You call them and they stop what they're doing. More people would be alive today if there were more drug courts."

Another graduate tells the court that "getting arrested was the best Christmas present I ever got", before announcing "and now I'm going to cry." Durkin joins in the weeping.

Of course, even in Courtroom 4, things do not always turn out so well. Just over half of those who attempt the drug court program complete it, says the judge. And some of those who do relapse into addiction, even if they don't commit new crimes. Drug court co-ordinator Amy Klumpp, who keeps in touch with hundreds of grads on Facebook, estimates that about 38 percent later relapse.

Some even relapse the night before the ceremony. Klumpp describes the periods right before and immediately after graduation as the most dangerous: sometimes participants hang on desperately to sobriety just long enough to graduate — and then go back to using. Sometimes they die. Of those who graduated in April, about a third are believed to have relapsed. One participant failed to show up for the most recent graduation ceremony because he had been in a serious accident the night before; he later died of an overdose.

Klumpp memorializes these losses in what she calls a "death wall" in her office. So far, there are five people from the drug court program on her wall who have died. Drug court extends a slender reed of hope but sometimes that simply is not enough.

Amy Tran doesn't remember how many times she brought her fiancé Matthew McFarland back from the dead, by administering the overdose antidote they kept around the house. "I wanna say about a handful of times," she says.

We are 400 miles away from Youngstown, across a broad swath of the Midwest opioid belt. This is a very different outpost of America's addiction wars: the urban, ex-urban and suburban areas of the Midwest's biggest city, Chicago, whose Cook County courthouse also has its own remarkably successful drug court. McFarland is a graduate.

Tran, a petite, bob-haired descendant of Vietnamese immigrants, is seated on the sofa of the modest condominium that the couple share with McFarland's mother, Beverly — the condo was rebuilt after McFarland burnt the original to the ground in 2003. "I nodded off on heroin, I dropped a cigarette on a pillow, and when I realized the pillow was on fire, I just tossed it over the stair railing and nodded back off," he recounts, as his mother listens, chiming in: "He never told me that bit before."

"I ran back in to get my leather jacket because it had five bags of heroin in it," he says, recalling the sight of the melting leather. And that was even before he drained $220,000 from his mother's retirement account to feed his habit.

These are the far southern suburbs of Chicago, a working-class area where McFarland, 46, has spent most of his life. He reckons he became an addict at the age of nine — helped by an alcoholic pharmaceutical salesman father who left drug samples lying around, not to mention storing "bags of reefer" in the living room.

Most people frame their college diplomas and mount them on the wall, he quips, as he shows us around the condo, with Oscar the Pekinese following along. His bedroom walls display a drug court graduation certificate instead. It's hard to imagine that less than three years ago, this trim, eager-to-please figure was doing anything he could to finance his own habit.

But then he pulls up the sleeve of his smart blue shirt — the kind of attire he would never have needed back then — and displays the deep grooves cut into his forearm where years of heroin use have collapsed the veins. And he tells the story of how a kid like him, who grew up in a house with a neat plaid cloth on the kitchen table and numbers for the veterinarian and the pizza delivery guy on the fridge, ended up with arms gouged by opioids.

McFarland's addiction went on for decades but the final act started in 2012. "My daughter's mother relapsed and left my daughter in a drug house, my father died and I was diagnosed with hepatitis C and taking medication that made me very sick. I went to the doctor who — despite knowing I was a recovering addict, and despite me arguing with him — prescribed me Xanax. I went across the street to Walgreens, filled the prescription, took two pills and then I felt my heart sink: what have I done? I grabbed a bottle out of the beverage section, took the rest of the bottle of pills before I got to the cashier. By the time I got to the parking lot, I was already calling people, trying to get more."

When he got arrested for the final time on December 8 2015, he was down to 120lb, and looked decades older than his fortysomething years. The face in his jail booking photo is haggard, blank-eyed and ghastly. Today's McFarland — who has been sober since the day after that arrest — laughs easily at the death he cheated by going to drug court. In July this year, he regained custody of his daughter. "One of the big things [about the drug court] was it got me out of the situation — the immediate, acute craziness that was going on in my life," he says. "The other thing is it was a support network for me… [it] provided me with some stability and some cheerleaders."

Across the table is McFarland's friend from his drug-taking days. Arthur Jones (not his real name) was "raised up in the ghetto" by strict Southern parents who tried hard but could not prevent him from becoming involved in drugs. He graduated in May from Cook County drug court. Most graduates of that court are, like Jones (and unlike McFarland), African-American: a potent reminder that though opioid abuse is widely seen as a "white" problem, its grip on black communities is also lethal.

In fact, the death toll from drug overdoses is now rising faster in African-American inner city communities than in the white suburbs. According to figures from the US Centers for Disease Control and Prevention, overdose deaths among black Americans rose 40 percent to 17.1 deaths per 100,000 in 2016, compared with a 20 percent rise to 25.3 per 100,000 for white Americans.

Thanks to drug court, both men gained new jobs: Jones as a machine operator, taking two buses and Chicago's elevated metro two-and-a-half hours each way to work. McFarland works at Safer Foundation, a Chicago non-profit that helps to place drug court graduates and other ex-offenders in the jobs that are so crucial to keeping them clean.

McFarland counts himself miraculously lucky to have got himself in so much legal trouble that the judicial system finally stepped in to help save him. Jones, though, lost his job when he relapsed soon after graduation. Sometimes drug court is just a first step to a recovery that still takes time, say those with long experience of therapeutic jurisprudence; and, of course, sometimes graduates do not stay alive long enough to try again.

"It's easier to go to the penitentiary than to finish one of these [drug court] programs. Much easier," says Judge Charles Burns, who presides over one of Cook County's drug courts. But of those who graduate, "91 percent have not picked up a felony arrest after a year", and 85 percent are still arrest-free after five years. "And these were frequent fliers, people getting arrested a couple of times a month before that," he says. "I'm not so naive that I think they won't struggle with addiction for the rest of their lives, but at least they are not involved in the criminal justice system. Every graduation, I drink the Kool-Aid," he says.

Drug court works, he thinks, "because it's so intensive". "The biggest influence on outcomes is length of treatment engagement: those who are mandated to attend treatment have better outcomes because they keep going."

Cook County officials, rehab specialists and those who work getting drug court graduates back into jobs say it can cost as much as $50,000 a year to keep someone in the county jail, or $38,000 in a state penitentiary, not counting the cost of caring for dependent children. In contrast, rehabilitation for a year outside jail costs $8,000-$9,000, plus maybe another $8,000 preparing them for a career that could mean a lifetime of productivity. After nearly three decades of drug courts demonstrating that they can cost less — and work better — than other alternatives, more communities have set up new ones, or have plans to do so.

"Over the years, drug courts have been shown to be effective at decreasing recidivism rates for adult drug court participants," says Regina LaBelle, who was chief of staff in the White House Office of National Drug Control Policy under former president Barack Obama.

The US Bureau of Justice Assistance, part of the US Department of Justice, says "Numerous national studies and individual program evaluations, including the Government Accountability Office, have confirmed that drug courts reduce drug use and recidivism," and adds that "several studies suggest that drug court outcomes last for many years following participation in the program". One study from Baltimore, the bureau notes, shows lower new criminal arrests, charges and convictions for drug court participants after 15 years.

President Donald Trump's opioid commission recommended last year that drug courts be expanded throughout the country as a key element of tackling the opioid crisis, noting that "44 percent of US counties do not have an adult drug court", despite them being "significantly more effective than incarceration". Shannon Carey of NPC research says the availability of federal funds to support drug court programs has increased significantly in recent months.

But only a small proportion of those who need help get it — or for that matter, want it; some choose the "easier" path of prison. Drug court judges are increasingly trying to pick for success, by putting the highest-risk, most desperate cases into drug court, on the assumption that they may be the most willing to work hard on getting clean.

Durkin says that, even after all this time, he can't predict who will succeed and who will fail. And even those who drop out, or relapse afterwards, may still have their lives changed by drug court, he says. "Sometimes they come up to me years later and say, 'I didn't get it when I was in your court, but guess what, now I'm two years clean, because you gave me the tools,'" he says. "Those who graduate today, they may relapse tonight, they may relapse a year from now, hopefully they don't die." But they may get clean in the end, he says, because they were "exposed to recovery" through the courts.

More from the Financial Times:

Ending America's opioid crisis requires more than a moral crusade

Why rising temperatures are bad for our mental health

'How to speak millennial'