The burden of community-associated Clostridium difficile infection (CA-CDI) has increased. We aimed to describe the epidemiology of CA-CDI to inform future interventions. We used population-based linked surveillance data from 2012 to 2016 to describe socio-demographic factors, ribotype and mortality for all CA (n = 1303) and hospital-associated (HA, n = 1356) CDI. For 483 community-onset (CO) CA-CDI and 287 COHA-CDI cases, a questionnaire on risk factors was completed and we conducted a case–case study using logistic regression models for univariate and multivariable analysis. CA-CDI cases had lower odds of being male (adjusted odds ratio (AOR) 0.71, 95% confidence interval (CI) 0.58–0.87; P < 0.001), and higher odds of living in rural rather than urban settlement (AOR 1.5, 95% CI 1.1–2.1; P = 0.05) compared with HA-CDI cases. The distribution of ribotypes was similar in both groups with RT078 being most prevalent. CDI-specific death was lower in CA-CDI than HA-CDI (7% vs. 11%, P < 0.001). COCA-CDI had lower odds of having had an outpatient appointment in the previous 4 weeks compared with COHA-CDI (AOR 0.61; 95% CI 0.41–0.9, P = 0.01) and lower odds of being in a care home or hospice when compared with their own home, than COHA-CDI (AOR 0.66; 95% CI 0.45–0.98 and AOR 0.35; 95% CI 0.13–0.92, P = 0.02). Exposure to gastric acid suppressants (50% in COCA-CDI and 55% in COHA-CDI) and antimicrobial therapy (18% in COCA-CDI and 20% in COHA-CDI) prior to CDI was similar. Our analysis of community-onset cases suggests that other risk factors for COHA-CDI may be equally important for COCA-CDI. Opportunities to safely reduce antibiotic and gastric acid suppressants use should be investigated in all healthcare settings.