For those in the outside world accustomed to paying $25 or more at every doctor’s visit, the idea of prisoners paying $2 to $8 to see a doctor seems nominal. Forty-two states plus the federal Bureau of Prisons charge a co-pay, according to the Prison Policy Initiative, a criminal justice think tank.

When you’re making pennies an hour, or nothing at all, a small co-pay can be the equivalent of hundreds of dollars.

Illinois lawmakers want to change that in their state. They voted last week to eliminate the $5 co-pay the state’s prisons have been charging for years. “When you’re denied your liberty, medical care is part of the deal. If you need it, you should get it,” said Jennifer Vollen-Katz, executive director of the John Howard Association, a state prison watchdog group that pushed the legislation. In letters and surveys, co-pays consistently emerged as one of prisoners’ biggest concerns, Vollen-Katz said, with more than half saying they avoid health care to avoid the co-pay.

Prisons charge co-pays for similar reasons as free-world health insurers: to cut down on unnecessary medical visits by requiring patients to share in the cost of their care. U.S. prisons spend between $3,000 and $10,000 per inmate per year on medical care—about 20 percent of total prison spending—according to a 2014 analysis by the Pew Charitable Trusts.

“We want a real-world environment for the prisoners because in the real world you and I would be required to have a copay,” Mark Myers, spokesman for the Oklahoma Department of Corrections, told the news site the Frontier. Prisoners in Oklahoma earn 5 cents per hour at the bottom of the wage scale, so the state’s $4 co-pay is roughly equivalent to $580 for a minimum wage worker on the outside, the Frontier reported.

Most states charge a fee for each visit, with a $3.47 national average, according to the Prison Policy Initiative's 2017 analysis. At $8 per visit, Nevada’s prison co-pay is the highest in the nation. “Charging a co-pay encourages the inmates to develop personal responsibility for their health care, it helps manage the volume of unnecessary doctor appointments in the clinics and assists with a small portion of the medical costs,” said Brooke Santina, spokeswoman for the Nevada Department of Corrections.

Texas charges inmates $100 per year—which officials are looking to double in the face of rising health care costs. Co-pay programs generally have carve-outs for inmates who can’t afford to pay and exceptions for chronic and communicable conditions—though some inmates have reported these exceptions being ignored or applied unevenly.

Despite their toll on inmates’ individual finances, the fees don’t add up to much on prisons’ balance sheets. In Illinois, the $5 co-pay brings in about $400,000 per year—not enough to recoup the administrative costs of running the program, according to Department of Corrections spokeswoman Lindsey Hess. A 2012 brief by the Oregon Department of Corrections—which only charges a co-pay in limited circumstances like elective care and eyeglasses—estimated administering a broader co-pay program would cost the department $3 to $5 per visit.

A single inmate who is hospitalized because he put off a visit to the doctor until his condition worsened can be enough to wipe out any cost savings, says Dr. Marc Stern, a correctional health care consultant and former assistant secretary of health care at the Washington state Department of Corrections. Washington charges inmates a $4 co-pay, a practice that “is difficult to defend,” Stern wrote in a 2007 memo to the department.

With prisoners living in close quarters, any policy that deters people from going to the doctor also increases the risk of contagion. In 2003, the federal Centers for Disease Control and Prevention identified inmate co-pays as one of the factors contributing to an outbreak of the super-bug MRSA among prisoners in Georgia, California and Texas. The National Commission on Correctional Health Care, which accredits prison and jail health care programs, cited this outbreak as one of the reasons it opposes fee-for-service or co-pay programs behind bars.

In Illinois, the Department of Corrections took a neutral position on the bill to eliminate co-pays, says Hess, the spokeswoman.

The bill next goes to Gov. Bruce Rauner for his signature. He did not respond to a Marshall Project inquiry about whether he plans to sign it.

Correction: An earlier version of this story used the wrong name for the Prison Policy Initiative.