BackgroundAn individual's suicide risk is determined by personal characteristics, but is also influenced by their environment. Previous studies indicate a role of contextual effects on suicidal behaviour, but there is a dearth of quantitative evidence from Asia.MethodsIndividual and community level data were collected on 165,233 people from 47,919 households in 171 communities in rural Sri Lanka. Data were collected on individual (age, sex, past suicide attempts and individual socioeconomic position (SEP)) and household (household SEP, pesticide access, alcohol use and multigenerational households) level factors. We used 3-level logit models to investigate compositional (individual) and contextual (household/community) effects.ResultsWe found significant variation between households 21% (95% CI 18%, 24%) and communities 4% (95% CI 3%, 5%) in the risk of a suicide attempt. Contextual factors as measured by low household SEP (OR 2.37 95% CI 2.10, 2.67), low community SEP (OR 1.45 95% CI 1.21, 1.74), and community ‘problem’ alcohol use (OR 1.44 95% CI 1.19, 1.75) were associated with an increased risk of suicide attempt. Women living in households with alcohol misuse were at higher risk of attempted suicide. We observed a protective effect of living in multigenerational households (OR 0.53 95% CI 0.42, 0.65).LimitationsThe outcome was respondent-reported and refers to lifetime reports of attempted suicide, therefore this study might be affected by socially desirable responding.ConclusionsOur study finds that contextual factors are associated with an individual's risk of attempted suicide in Sri Lanka, independent of an individual's personal characteristics.