The purpose of the study was to examine risk factors for nosocomial pneumonia in the surgical and medical/respiratory intensive care unit (ICU) populations. In a public teaching hospital, all cases of nosocomial pneumonia in the surgical and medical/respiratory ICUs (n = 20, respectively) were identified by prospective surveillance during a 5-yr period from 1987-1991. Each group of ICU cases was compared with 40 ICU control patients who did not acquire pneumonia, and analyzed for 25 potential risk factors. Surgical ICU patients were found to have consistently higher rates of nosocomial pneumonia than medical ICU patients (RR = 2.2). The strongest predictor for nosocomial pneumonia in both the surgical and medical/respiratory ICU groups was found to be prolonged mechanical ventilation (> 1 d) resulting in a 12-fold increase in risk over nonventilated patients. APACHE III score was found to be predictive of nosocomial pneumonia in the surgical ICU population, but not in the medical/respiratory ICU population. We conclude that certain groups deserve special attention for infection control intervention. Surgical ICU patients with high APACHE scores and receiving prolonged mechanical ventilation may be at the greatest risk of acquiring nosocomial pneumonia of all hospitalized patients.