All cancers are caused by somatic mutations; however, understanding of the biological processes generating these mutations is limited. The catalogue of somatic mutations from a cancer genome bears the signatures of the mutational processes that have been operative. Here we analysed 4,938,362 mutations from 7,042 cancers and extracted more than 20 distinct mutational signatures. Some are present in many cancer types, notably a signature attributed to the APOBEC family of cytidine deaminases, whereas others are confined to a single cancer class. Certain signatures are associated with age of the patient at cancer diagnosis, known mutagenic exposures or defects in DNA maintenance, but many are of cryptic origin. In addition to these genome-wide mutational signatures, hypermutation localized to small genomic regions, ‘kataegis’, is found in many cancer types. The results reveal the diversity of mutational processes underlying the development of cancer, with potential implications for understanding of cancer aetiology, prevention and therapy. An analysis of mutations from over 7,000 cancers of diverse origins reveals the diversity of mutational processes underlying the development of cancer; more than 20 distinct mutational signatures are described, some of which are present in many cancer types, notably a signature attributed to the APOBEC family of cytidine deaminases, whereas others are specific to individual tumour types. Despite the fact that all cancers are thought to result from somatic mutation — mutations in any cell in the body excluding the germ cells — relatively little is known about the processes of mutation involved. This study analyses almost 5 million mutations from more than 7,000 cancers and demonstrates more than 20 distinct cancer-associated mutational signatures. Some of these signatures are present in many cancers, notably a signature attributed to the APOBEC family of cytidine deaminases, whereas others are specific to individual tumour types. Some signatures are associated with age, known mutagenic exposures or defects in DNA maintenance, but many are of cryptic origin. These findings have potential implications for the understanding of cancer aetiology, prevention and therapy.