Health officials say the rate of HIV among people who are incarcerated is nearly seven times higher than the general population.
In a downtown San Francisco jail, a guard checks on the cells that line the central corridor. This high-security facility is home to more than 800 inmates.
Inside the gym, there's a machine that distributes free condoms. It's the only condom machine inside a jail or prison in California. And it's one of only two jail condom distribution programs in the state.
San Francisco's long-time Sheriff Michael Hennessey says his program began in 1989, when AIDS was ravaging the city. Hennessey says he felt he needed to do something.
"So we started by printing up a little brochure, and when people would get out of jail, and pick up their property, we would give them the brochure, and we would scotch tape a condom to the brochure," Hennessey recalled. "And then after we'd done that for awhile, we thought probably the better thing would be to actually provide the condoms in the jail as a form of AIDS education."
Hennessey admits he had some reservations about it. He was concerned inmates could hide drugs in the condoms, or that sexual assaults would increase. His staff had some objections, too.
"They are the ones working the jails and they're very concerned about contraband of any kind," Hennessey pointed out. "There was certainly some homophobia, even though AIDS is not a gay disease, at the time it was viewed that way, back in the 80s."
However, after Hennessey talked with the wardens of some jail systems back east that handed out condoms, his fears went away.
In the beginning, inmates in the San Francisco jail could get a condom from a health educator. The machine came later.
Los Angeles became the second county in the state to offer a condom distribution program in its jails in 2001.
So far, no other county in the state has followed suit.
Captain Dan Pena runs the detention support division for the San Diego County Sheriff's Department. He oversees seven jails and nearly 5,200 inmates.
Pena says his department has no interest in handing out condoms.
"Primarily the reason for that, is sexual activity in jails or prisons is illegal; it's actually a felony," Pena said. "And because of that, we would not want to send a mixed message to the inmate population that knowing this is a crime, here's a condom. So that's our primary position."
Pena says San Diego County controls HIV in jails through education, and strict supervision of inmates. He says until there's evidence that handing out condoms in jail reduces the rate of HIV, the county won't change its approach.
San Francisco Sheriff Michael Hennessey thinks that's shortsighted. In fact, he thinks most sheriffs throughout California are wrong on this issue.
"They don't see the spreading of venereal diseases or HIV in their community a matter for law enforcement, whereas I do," Hennessey said. "And I see it also as people who run jails and prisons have an opportunity to educate people when they're in their custody."
Mary Sylla is the policy and advocacy director for the non-profit Center for Health Justice. She admits it's hard for most corrections officials to embrace condom distribution.
"It's a lot like syringe exchange, and you know, not very many communities in the nation have syringe exchange," Sylla said. "It takes a little bit of a shift in terms of thinking about public safety."
San Francisco County has studied the effects of its program. Officials say sexual activity in jail has not increased. There have been no reports of smuggling with condoms. Inmates report they have engaged in less high-risk behavior.
Based on San Francisco County's model, the state of California recently ended a one-year pilot program in Solano State prison. Some 2,000 inmates had access to a condom machine.
The state is currently evaluating the program. In the meantime, less than ten jails or prison systems nationwide distribute condoms.