Background. Nosocomial transmission of tuberculosis remains an important public health problem. We created an in vivo air sampling model to study airborne transmission of tuberculosis from patients coinfected with human immunodeficiency virus (HIV) and to evaluate environmental control measures. Methods. An animal facility was built above a mechanically ventilated HIV-tuberculosis ward in Lima, Peru. A mean of 92 guinea pigs were continuously exposed to all ward exhaust air for 16 months. Animals had tuberculin skin tests performed at monthly intervals, and those with positive reactions were removed for autopsy and culture for tuberculosis. Results. Over 505 consecutive days, there were 118 ward admissions by 97 patients with pulmonary tuberculosis, with a median duration of hospitalization of 11 days. All patients were infected with HIV and constituted a heterogeneous group with both new and existing diagnoses of tuberculosis. There was a wide variation in monthly rates of guinea pigs developing positive tuberculin test results (0%-53%). Of 292 animals exposed to ward air, 159 developed positive tuberculin skin test results, of which 129 had laboratory confirmation of tuberculosis. The HIV-positive patients with pulmonary tuberculosis produced a mean of 8.2 infectious quanta per hour, compared with 1.25 for HIV-negative patients with tuberculosis in similar studies from the 1950s. The mean monthly patient infectiousness varied greatly, from production of 0-44 infectious quanta per hour, as did the theoretical risk for a health care worker to acquire tuberculosis by breathing ward air. Conclusions. HIV-positive patients with tuberculosis varied greatly in their infectiousness, and some were highly infectious. Use of environmental control strategies for nosocomial tuberculosis is therefore a priority, especially in areas with a high prevalence of both tuberculosis and HIV infection.