A population-based cohort with inflammatory bowel disease consisting of 4776 patients (3121 with ulcerative colitis and 1655 with Crohn's disease) was followed for 1 to 50 years for the occurrence of malignant neoplasms. Two hundred eighty-three cancers were observed versus 189.1 expected (standardized incidence ratio [SIR] = 1.5, 95% confidence limits [CL] 1.3 to 1.7). One hundred seventy-eight extracolonic cancers were observed versus 168.8 expected (SIR = 1.1, 95% CL 0.9 to 1.2). In Crohn's disease and extensive ulcerative colitis, observed cases were close to those expected but in ulcerative proctitis, the relative risk of extracolonic cancers was close to significantly increased (SIR = 1.3, 95% CL 1.0 to 1.7). Squamous skin cancers after Crohn's disease (SIR = 5.5, 95% CL 2.0 to 11.9) and connective tissue cancers after ulcerative colitis (SIR = 4.0, 95% CL 1.0 to 10.2) were significantly increased. Those having extensive ulcerative colitis at diagnosis had an increased risk of brain cancers (SIR = 2.4, 95% CL 1.0 to 4.6). Patients with extensive ulcerative colitis had lower than expected risk of breast cancer (SIR = 0.4, 95% CL 0.1 to 1.0).