Background: We have assessed the extent to which the risk of serious gastrointestinal complications from nonaspirin nonsteroidal anti-inflammatory drugs (NANSAIDs) varies with the age and sex of recipients, use of aspirin or alcohol, administration by the oral or rectal route, and dose and choice of drug. Methods: A case-control study was performed with prospective recruitment of cases of gastrointestinal bleeding or ulcer perforation and age- and sex-matched controls. Information on preadmission drug use obtained by structured interview. Results: Six hundred forty-four patients and 1268 controls were recruited. The odds ratio for upper gastrointestinal complications in users compared with nonusers of NANSAIDs increased with age: ≤ 59 years, odds ratio 2.0; 60-79 years, odds ratio 3.0; ≥ 80 years, odds ratio 4.2; and was higher in women (5.4) than in men (1.9). There was a linear dose-response curve that was steeper in women than in men. Combined exposure suggested additive risks: NANSAIDs and aspirin, odds ratio 6.7; NANSAIDs and alcohol, odds ratio 6.0. NANSAIDs by the oral route were associated with an odds ratio of 2.3, compared with 11.4 with rectal administration. Piroxicam was associated with the highest risk, odds ratio 4.8; and ibuprofen the lowest risk, odds ratio 0.7. Conclusions: A number of factors can alter the risk of major gastrointestinal complications with NANSAIDs and need to be considered when individual prescribing decisions are made.