Background: Despite the high prevalence of constipation and its related public health implications, there is relatively little research available on the condition from large epidemiological studies. The aim of this study was to investigate the epidemiology of general practitioner (GP)-diagnosed constipation and the prescribing trends for laxatives in the UK, within the general population and during pregnancy.Methods: A cohort study for the period from 2005 to 2009 was performed using the UK primary care database (General Practice Research Database), which contains information on over 3 million individuals.Results: The prevalence of GP-diagnosed constipation ranged from 12 per 1000 persons in 2005 (0.012 per person year) to 12.8 per 1000 in 2009 (0.013 per person year). The prevalence was almost twice as high in women as in men, and was higher in older patients. In 2005 the most commonly prescribed laxatives were lactulose (37%), senna (26%), macrogol (19%), ispaghula (6%), docusate sodium (5%), bisacodyl (4%) and glycerol suppositories (2%). By 2009, this pattern had changed: macrogol (31%), lactulose (29%), senna (22%), ispaghula (5%), docusate sodium (6%), bisacodyl (3%) and glycerol suppositories (3%). In pregnancy, lactulose accounted for 81% of laxative use in 2005, falling to 64% by 2009. In contrast, macrogol use in pregnancy rose from 13% in 2005 to 32% in 2009.Conclusions: GP-diagnosed constipation is common, accounting for a large number of consultations. Laxative prescribing trends have changed over the 5-year study period, prescriptions for macrogol becoming increasingly common and prescriptions for lactulose and senna less common. Macrogol also appears to have been replacing lactulose for treating constipation in pregnant women. © 2011 The Author(s).