SACRAMENTO, Calif. — The federal official who controls medical care in California prisons on Monday ordered thousands of high-risk inmates out of two Central Valley prisons in response to dozens of deaths due to Valley fever, which is caused by an airborne fungus.

Medical receiver J. Clark Kelso ordered the Department of Corrections and Rehabilitation to exclude black, Filipino and other medically risky inmates from Avenal and Pleasant Valley state prisons because those groups are more susceptible to the fungal infection, which originates in the region’s soil.

Aside from the racial minorities, high-risk inmates include those who are sick, infected with HIV, are undergoing chemotherapy or otherwise have a depressed immune system. In addition to the deaths, the fungus has hospitalized hundreds of inmates.

The order will affect about 40 percent of the more than 8,200 inmates at the two prisons, said Joyce Hayhoe, a spokeswoman for the receiver’s office.

“The state of California has known since 2006 that segments of the inmate population were at a greater risk for contracting Valley fever, and mitigation efforts undertaken by CDCR to date have proven ineffective,” she said in an emailed statement. “As a result, the receiver has decided that immediate steps are necessary to prevent further loss of life.”

That creates problems for the corrections department, which faces a December deadline to reduce overcrowding in prisons statewide by an additional 9,000 inmates as part of a federal court order to improve medical and mental health care.

The department must file a plan with the federal courts by Thursday outlining what steps it will take to reduce the prison population by year’s end. Corrections Secretary Jeffrey Beard has said the department still wants to bring home more than 8,400 inmates who currently are being housed in private prisons in other states.

Gov. Jerry Brown has been threatened with contempt of court if he does not meet the court-ordered population reduction, though he has promised to appeal to the U.S. Supreme Court. Kelso’s directive further undermines the Democratic governor’s attempts to regain control of state prisons after two decades of federal oversight.

In response to the receiver’s order Monday, corrections department spokesman Jeffrey Callison said, “To implement this policy directive would be a big undertaking, and we’re reviewing it.”

The department had been focused on trying to minimize the spread of the dust that carries the spores that cause Valley fever.

“If there are ways to reduce or prevent Valley fever, period, regardless of who the inmates are, that would probably be the best thing all around,” Callison said.

Steps include controlling dust measures during construction, giving surgical masks to inmates and employees who request them, and providing education materials to employees and inmates. The corrections department is installing air filters and is considering measures to cover up dusty areas and screen out more dust from entering prison buildings.

Those efforts are not getting the job done, according to both the receiver and the nonprofit Prison Law Office that is asking a federal judge to intervene.

The issue is part of a lawsuit filed more than a decade ago seeking to improve medical care in the state’s 33 adult prisons. It surfaced again Monday after a doctor hired by the law firms representing inmates filed a sworn declaration with the federal court saying the prisons should be shut down.

“The governor has said the prison system isn’t crowded and it’s providing the finest health care that money can buy. Here’s another example why that isn’t true,” said Don Specter, director of the Prison Law Office. “Prisoners are dying because they’re in a toxic environment which causes serious illness and death on a regular basis. The department has known about this problem since about 2007 and has done virtually nothing.”

The federal judge overseeing the case has scheduled a court hearing on the matter for June.

Valley fever is found most often in the southwestern United States, with about a quarter of the cases in California and more than 70 percent in Arizona, according to the Centers for Disease Control and Prevention. The number of cases has risen over the years and topped 20,000 in 2011, the CDC reported in December.

In a sworn declaration, Dr. John Galgiani said the situation at the Pleasant Valley and Avenal prisons is a “public health emergency.” Galgiani is a professor of medicine at the University of Arizona who founded a center where Valley fever is researched.

The communities surrounding the prisons in the southern San Joaquin Valley have the highest rates of the disease in California, but Galgiani said the infection rates at both prisons are even higher than those.

Warren George, an attorney with the Prison Law Office, said Valley fever was a contributing factor in 34 inmate deaths between 2006 and 2011. Since 2012, it has been a primary or secondary cause of nine inmate deaths.

The receiver’s office estimates the illnesses cost taxpayers more than $23 million a year to treat.

Inmates in the federal prison system have also claimed that the disease affects them disproportionately and that the government has failed to protect them.

In August 2012, the U.S. Department of Justice, while admitting no fault, settled a case with a former federal inmate at the Taft Correctional Institution in Kern County for $425,000. During an epidemic in the prison in 2003-2004, as many as 88 inmates contracted the disease, according to the CDC. Two other similar cases are pending involving federal inmates at Taft.


Associated Press writer Gosia Wozniacki in Fresno contributed to this report.