Patients with a definite diagnosis of ulcerative colitis in Stockholm County during the 35-year period 1945-79 were identified and followed up with regard to the development of cancer of the colon. We found 25 patients who had developed 31 cancers. In 24 of 25 cases this occurred in patients with total colitis. The cumulative risk of developing cancer for patients with total colitis at follow-up study was calculated by means of life-table methods. It was 13% at 25 years (SD +/- 4.2%) among patients diagnosed in 1945-79, compared with the 1.9% expected in a population matched for age and sex. Among patients diagnosed in 1955-79 the risk was approximately 5% at 20 years (SD +/- 3.0%), compared with 1.4% for the background population. The cancer risk for all patients with colitis was higher but not significantly higher than that of the general population. The outcome of patients who developed cancer was dependent on histologic staging (Dukes's) at surgery but not on age at cancer diagnosis.