Community-acquired pneumonia (CAP) is a serious social and medical problem in the elderly. Mortality, hospitalization and length of stay increase with age. The aim of this study was to determine the risk factors associated with prolonged hospital stay in elderly patients with CAP. Clinical and laboratory data were collected for 115 community-living patients, 65 years old and over, admitted to the geriatric ward of a University Hospital from 1995 to 1998 because of symptoms and signs of pneumonia confirmed by a pulmonary infiltrate on chest x-ray. We divided the patients into two groups, with length of stay more than 13 days (70 patients, cases), and length of stay less than 13 days (45 patients, controls) according to Diagnosis Related Groups criteria for complicated and uncomplicated pneumonia, respectively. A prolonged hospital stay was associated with a higher fever peak and a higher number of days with fever (p<0.005), greater comorbidity (p<0.001), urinary catheterization and secondary urinary infections (p<0.001), higher erythrocyte sedimentation rate (p<0.001), dehydration (p<0.005), and caloric-proteic malnutrition (p=0.01). In conclusion, knowledge of the risk factors for prolonged hospital stay in elderly patients with CAP may be used to identify high-risk patients, prevent the risks with prophylactic measures, and contain the costs of hospitalization.