Safe water systems (SWSs) have been shown to reduce diarrhea and death. We examined the cost-effectiveness of SWS for HIV-affected households using health outcomes and costs from a randomized controlled trial in Tororo, Uganda. SWS was part of a home-based health care package that included rapid diarrhea diagnosis and treatment of 196 households with relatively good water and sanitation coverage. SWS use averted 37 diarrhea episodes and 310 diarrhea-days, representing 0.155 disability-adjusted life year (DALY) gained per 100 person-years, but did not alter mortality. Net program costs were 5.21 dollars/episode averted, 0.62 dollars/diarrhea-day averted, and 1,252 dollars/DALY gained. If mortality reduction had equaled another SWS trial in Kenya, the cost would have been 11 dollars/DALY gained. The high SWS cost per DALY gained was probably caused by a lack of mortality benefit in a trial designed to rapidly treat diarrhea. SWS is an effective intervention whose cost-effectiveness is sensitive to diarrhea-related mortality, diarrhea incidence, and effective clinical management.