Background: We aimed to accurately estimate the frequency of a hexanucleotide repeat expansion in C9orf72 that has been associated with a large proportion of cases of amyotrophic lateral sclerosis (ALS) and frontotemporal dementia (FTD). Methods: We screened 4448 patients diagnosed with ALS (El Escorial criteria) and 1425 patients with FTD (Lund-Manchester criteria) from 17 regions worldwide for the GGGGCC hexanucleotide expansion using a repeat-primed PCR assay. We assessed familial disease status on the basis of self-reported family history of similar neurodegenerative diseases at the time of sample collection. We compared haplotype data for 262 patients carrying the expansion with the known Finnish founder risk haplotype across the chromosomal locus. We calculated age-related penetrance using the Kaplan-Meier method with data for 603 individuals with the expansion. Findings: In patients with sporadic ALS, we identified the repeat expansion in 236 (7·0%) of 3377 white individuals from the USA, Europe, and Australia, two (4·1%) of 49 black individuals from the USA, and six (8·3%) of 72 Hispanic individuals from the USA. The mutation was present in 217 (39·3%) of 552 white individuals with familial ALS from Europe and the USA. 59 (6·0%) of 981 white Europeans with sporadic FTD had the mutation, as did 99 (24·8%) of 400 white Europeans with familial FTD. Data for other ethnic groups were sparse, but we identified one Asian patient with familial ALS (from 20 assessed) and two with familial FTD (from three assessed) who carried the mutation. The mutation was not carried by the three Native Americans or 360 patients from Asia or the Pacific Islands with sporadic ALS who were tested, or by 41 Asian patients with sporadic FTD. All patients with the repeat expansion had (partly or fully) the founder haplotype, suggesting a one-off expansion occurring about 1500 years ago. The pathogenic expansion was non-penetrant in individuals younger than 35 years, 50% penetrant by 58 years, and almost fully penetrant by 80 years. Interpretation: A common Mendelian genetic lesion in C9orf72 is implicated in many cases of sporadic and familial ALS and FTD. Testing for this pathogenic expansion should be considered in the management and genetic counselling of patients with these fatal neurodegenerative diseases. Funding: Full funding sources listed at end of paper (see Acknowledgments).