figure b

Introduction

It was estimated that 537 million adults aged 20–79 years were living with diabetes worldwide in 2021, with more than 90% of them having type 2 diabetes [1]. Type 2 diabetes is associated with a higher risk of several vascular complications, including myocardial infarction, stroke, peripheral artery disease and kidney disease, leading to premature death [2]. Previous studies have reported declining rates in the last two decades of major cardiovascular complications and mortality in people with diabetes in some high-income countries [3, 4], with parallel greater contributions of other diseases, such as cancer, as the underlying causes of death [5]. Accumulating epidemiological evidence has indeed shown a higher risk of incidence and mortality for some types of cancer in individuals with type 2 diabetes [6, 7], with prolonged exposure to the effects of hyperglycaemia, hyperinsulinaemia, insulin resistance and chronic inflammation being the potential underlying biological mechanisms [6, 8]. Robust evidence indicates that there is a causal relationship between type 2 diabetes and pancreatic, liver and endometrial cancer [7]; both diabetes and cancer have also been linked to obesity and smoking [6, 8].

While previous studies have extensively investigated inequalities in vascular outcomes among people with type 2 diabetes by sociodemographic factors [9,10,11,12], less is known about whether such inequalities exist in cancer mortality rates. In this study we aimed therefore to describe long-term trends in cancer mortality rates in people with type 2 diabetes based on subgroups defined by sociodemographic characteristics and risk factors.

Methods

Data sources

We conducted this study following a prespecified research protocol, which was approved by the Clinical Practice Research Datalink (CPRD) Independent Scientific Advisory Committee (No. 19_120Mn), and the RECORD guidelines (see checklist in the electronic supplementary material [ESM]) [13].

We used the CPRD GOLD database to identify a cohort of individuals with type 2 diabetes in the UK. The CPRD routinely collects de-identified patient data, which are generally representative of the national population in terms of age, sex and ethnicity [14]. Data were linked to the Hospital Episode Statistics (HES), patient-level Index of Multiple Deprivation (IMD) 2010 and Office for National Statistics (ONS) death registrations (https://cprd.com/cprd-linked-data) to extract further information on ethnicity and hospitalisations, socioeconomic status and date and cause of death, respectively. Linkages were available only for patients in England.

Study population

Individuals were included if they had a first-ever diagnosis code of type 2 diabetes in the CPRD between 1 January 1998 and 30 November 2018, were aged 35 years or over at the first diagnosis date of type 2 diabetes (i.e. the index date) and were registered with an up-to-standard practice for a minimum of 1 year at the index date. To rule out potential misclassification by clinical coding, individuals with a code of type 1 diabetes at any time in either the CPRD or HES were excluded. As the main outcome was cancer mortality, we only included individuals with linkage to ONS death registrations.

Procedures

Individuals were categorised into subgroups defined by gender, ethnicity, socioeconomic status, BMI and smoking status. Ethnicity was grouped as White and other than White; data were predominantly extracted from HES and supplemented with CPRD records when data were missing in HES. We used the patient-level IMD 2010 quintiles (the mid-point year of the study period) to define socioeconomic status (1st quintile: least deprived; 5th quintile: most deprived). The IMD measures the relative deprivation for small areas in England and includes seven domains: income, employment, health and disability, education, skills and training, barriers to housing and other services, crime and living environment [15]. Data on BMI (underweight: <18.5; normal weight: 18.5–24.9; overweight: 25.0–29.9; obese: 30.0–34.9; and severely obese: ≥35.0 kg/m2) and smoking status (non-smoker, current smoker and ex-smoker) were extracted from the CPRD using the values for the closest date before the index date.

Outcomes

The underlying cause of death was used to ascertain cancer deaths. To estimate the proportion of cancer deaths out of all-cause deaths, we also collected information on all-cause mortality. We further investigated deaths due to some specific cancers, including the four most common cancers in the UK (lung, colorectal, breast and prostate) and the four cancers causally linked to diabetes in a previous meta-analysis (i.e. pancreatic, liver, endometrial and gallbladder) [7]. All individuals were followed up from the index date until death or the end of study (linkage date for ONS data: 14 January 2019).

Statistical analysis

We reported baseline characteristics (at the index date) as medians and IQRs for continuous variables and numbers and proportions for categorical variables; we also calculated person-years and numbers of events overall and in each subgroup. To estimate trends in mortality rates, we first split the risk time into 1 year intervals by attained age and attained calendar time and then modelled the outcomes with Poisson regressions including an interaction between a natural spline transformation of age and calendar year (five knots placed at the 10th, 30th, 50th, 70th and 90th percentile distribution in those with events) and adjusting for diabetes duration [16, 17]. Using log(person-time) as an offset, we predicted age-specific mortality rates at the mid-point of each calendar year and at the median diabetes duration on exiting the cohort (8.4 years). To further assess the cancer burden over time, we calculated the proportion of cancer deaths out of all-cause deaths and used non-parametric bootstrap sampling (500 samples with replacement) to derive 95% CIs. We conducted stratified analyses by gender, ethnicity, deprivation, BMI and smoking status to investigate potential inequalities. Individuals with missing data on ethnicity, socioeconomic status, BMI or smoking status were not included in the corresponding stratified analyses (<10% missingness). For stratified models, we predicted the mortality rates at the median age on exiting the cohort (72 years) to make rates comparable across subgroups. We then used the predicted rates to explore mortality trends and estimated the annual percentage changes (APCs) for each calendar year segment and the average annual percentage changes (AAPCs) for the whole study period using the Joinpoint Regression Program 4.9.1.0 [18]. We also calculated the age- and sex-standardised mortality ratios (SMRs) (age standardised only in sex-stratified analyses) for all outcomes by the calendar periods identified in the Joinpoint regressions, with corresponding mortality rates in the general population obtained from publicly available data in England and Wales [19]. Analyses were conducted in R 4.2.1 [20] (‘Epi’ package [16]), Joinpoint Regression Program 4.9.1.0 and Stata/BE 17.0 (StataCorp LLC, USA).

Results

The study participant flow chart is provided in ESM Fig. 1. In total, 137,804 individuals were included in the analysis. Participant characteristics at type 2 diabetes diagnosis are shown in Table 1. The median age of participants was 63.8 years (IQR 54.2, 73.0); 61,444 (44.6%) were women; 114,394 (83.0%) were of White ethnicity; 64,652 (46.9%) were non-smokers; 16,126 (11.7%) had a normal body weight; and the median BMI was 30.6 kg/m2 (IQR 27.1, 34.9). During a median follow-up of 8.4 years (IQR 5.0, 12.2) and a total of 1,194,444 person-years, 39,212 (28.5%) deaths occurred. Table 2 reports the numbers of person-years and events stratified by each sociodemographic characteristic and risk factor.

Table 1 Baseline characteristics of individuals at type 2 diabetes diagnosis
Table 2 Person-years and numbers of events at follow-up by gender, ethnicity, socioeconomic status, BMI group and smoking status

All-cancer mortality rates

Figure 1, ESM Tables 16 and Table 3 present trends in all-cause and all-cancer mortality rates in different subgroups. Trends in all-cause mortality rates are described in detail in the ESM (see Additional results: All-cause mortality rates). Figure 2 shows the proportions of cancer deaths out of all-cause deaths in different subgroups.

Fig. 1
figure 1

Trends in all-cause mortality rates (af) and all-cancer mortality rates (gl) (per 1000 person-years). Age-specific mortality rates for all-cause mortality (a) and all-cancer mortality (g). All rates were estimated for the median diabetes duration at the end of follow-up (8.4 years). Rates stratified by gender (b, h), ethnicity (c, i), socioeconomic status (d, j), BMI (e, k) and smoking status (f, l) were also age-adjusted and are presented for the median age at the end of follow-up (72 years). Error bars indicate 95% CIs. The number of all-cancer deaths in people of ethnicities other than White was small in some years, leading to predicted rates with large uncertainties. All estimates are also reported in ESM Tables 16

Table 3 APCs and AAPCs in all-cause and all-cancer mortality rates
Fig. 2
figure 2

Proportions of cancer deaths out of all-cause deaths by age (ad), gender (e, f), ethnicity (g), deprivation (h, i), BMI (jm) and smoking status (np). Proportions were calculated as the all-cancer mortality rate divided by the all-cause mortality rate in each stratum and calendar year. Error bars indicate 95% CIs, which were estimated using the non-parametric bootstrap method with 500 replicates. The number of all-cancer deaths in people of ethnicities other than White was small in some years, leading to predicted rates with large uncertainties and unstable proportion estimates; only the proportions for White ethnicity are shown (g). All estimates are also reported in ESM Tables 16

Trends in and magnitudes of all-cancer mortality rates differed across age groups (Fig. 1g). During the whole study period, reductions were observed in younger age groups while increases were seen in older age groups: for 55-year-olds, the all-cancer mortality rate was 2.1 (95% CI 1.5, 3.1) per 1000 person-years in 1998, 2.4 (2.1, 2.7) in 2008 and 1.6 (1.2, 2.1) in 2018, with an AAPC of –1.4% (95% CI –1.5, –1.3) indicating an annual reduction of 1.4%. Corresponding rates and AAPCs were 5.2 (4.2, 6.4), 6.6 (6.0, 7.1), 4.9 (4.3, 5.7) and –0.2% (–0.3, –0.1), respectively, for 65-year-olds; 8.8 (7.0, 11.1), 14.9 (13.7, 16.2), 11.3 (9.9, 12.9) and 1.2% (0.8, 1.6), respectively, for 75-year-olds; and 14.7 (11.2, 19.4), 22.5 (20.6, 24.7), 19.8 (17.3, 22.6) and 1.6% (1.5, 1.7), respectively, for 85-year-olds (Fig. 1g; Table 3; ESM Table 1). Compared with other ages, the proportions of cancer deaths were noticeably lower but steadily increased in 85-year-olds during the whole study period (Fig. 2d; ESM Table 1). Proportions increased greatly in 75-year-olds but only slightly in 65-year-olds, followed by a flat trend after 2008 and 2012, respectively (Fig. 2b,c; ESM Table 1); proportions were constant for the youngest age group (Fig. 2a; ESM Table 1).

All-cancer mortality rates and proportions of cancer deaths were higher in men than women for most of the 1998–2018 period, with the gap in both rates and proportions being smaller around 2012–2014 and widening since 2014 (Figs 1h, 2e,f; ESM Table 2). AAPCs were 0.5% (95% CI 0.2, 0.8) in men and 1.5% (1.1, 1.8) in women (Table 3).

While all-cancer mortality rates increased before flattening and decreasing in people of White ethnicity, they decreased and then increased in people of other ethnicities, resulting in an overall increase in rate in people of White ethnicity (AAPC 2.4%; 95% CI 2.1, 2.6) and a reduction in people of other ethnicities (AAPC –3.4%; –3.6, –3.2) (Fig. 1i; Table 3; ESM Table 3). The proportion of cancer deaths increased slowly during the study period in people of White ethnicity (Fig. 2g) while it was not estimable in people with other ethnicities because of the small number of cancer deaths.

The deprivation gap in all-cancer mortality rates (most vs least deprived) was smallest around 2008 and widened thereafter (Fig. 1j; ESM Table 4). While the trends indicated increases in mortality rates in both the least and the most deprived groups from 1998 to 2018, the AAPC was slightly larger in the least deprived group (1.5%; 95% CI 0.7, 2.2) than in the most deprived group (1.0%; 0.9, 1.1) (Table 3). The proportions of cancer deaths increased from 1998 to 2008 in the least deprived group and from 2008 to 2013 in the most deprived group and then decreased and flattened in both groups; however, they were higher in the least deprived group than in the most deprived group for nearly all years during the study period (Fig. 2h,i).

All-cancer mortality rates at the beginning of the study were higher in people with normal weight than in people with overweight or morbid obesity. However, there were smaller increases in cancer mortality rates during the study period in individuals with normal weight (AAPC 0.7%; 95% CI 0.6, 0.9) than in those who were severely obese (AAPC 5.8%; 5.6, 6.1), resulting in no differences in cancer mortality rates between the two groups after 2012 (Fig. 1k; Table 3; ESM Table 5). During the entire study period we observed a sharply increasing trend in the proportions of cancer deaths in people who were overweight (Fig. 2k) or (severely) obese (Fig. 2l,m) but only a small increase in people with normal weight (Fig. 2j). Further, the proportions were similar in all BMI groups in 2018.

All-cancer mortality rates were appreciably higher in current than in former or non-smokers, particularly after 2008, with a progressively wider gap because of an increase in rates in current smokers (3.4%; 95% CI 3.4, 3.5) and former smokers (0.6%; 0.5, 0.8) but a reduction in non-smokers (–1.4%; –1.4, –1.3) (Fig. 1l; Table 3; ESM Table 6). The proportions of cancer deaths increased and then flattened in all three subgroups but such increases were sharper in current smokers (Fig. 2n) and former smokers (Fig. 2p) than in non-smokers (Fig. 2o); however, proportions across smoking groups were similar after 2010.

Cancer-specific mortality rates

Figure 3 shows the trends in mortality rates for breast, prostate, lung and colorectal cancer, the four most common cancers; ESM Table 7 reports the corresponding APCs and AAPCs by age, gender, ethnicity, socioeconomic status, BMI and smoking status. Of the four cancers causally linked to type 2 diabetes (pancreatic, liver, gallbladder and endometrial), Fig. 4 shows the trends in mortality rates only for pancreatic and liver cancer; because of the small number of events (Table 2), trends for gallbladder and endometrial cancer could not be estimated and stratified analyses were not possible. ESM Table 8 reports the corresponding APCs and AAPCs for all four cancers causally linked to type 2 diabetes by sociodemographic characteristics and risk factors.

Fig. 3
figure 3

Trends in cancer-specific mortality rates (per 100,000 person-years) for four common cancers: (ae) breast cancer, (fj) prostate cancer, (kp) lung cancer and (qv) colorectal cancer. Age-specific mortality rates for breast (a), prostate (f), lung (k) and colorectal (q) cancer. All rates were estimated for the median diabetes duration at the end of follow-up (8.4 years). Rates stratified by gender (l, r), ethnicity (b, g, m, s), socioeconomic status (c, h, n, t), BMI (d, i, o, u) and smoking status (e, j, p, v) were also age-adjusted and are presented for the median age at the end of follow-up (72 years). Error bars indicate 95% CIs. Stratified analysis by gender is not applicable for breast and prostate cancer. The number of breast and prostate cancer deaths in people of ethnicities other than White was small in some years, leading to predicted rates with large uncertainties

Fig. 4
figure 4

Trends in cancer-specific mortality rates for type 2 diabetes-related cancers (per 100,000 person-years). Age-specific mortality rates for pancreatic (a) and liver (g) cancer. All rates were estimated for the median diabetes duration at the end of follow-up (8.4 years). Rates stratified by gender (b, h), ethnicity (c, i), socioeconomic status (d, j), BMI (e, k) and smoking status (f, l) were also age-adjusted and are presented for the median age at the end of follow-up (72 years). Error bars indicate 95% CIs. The numbers of liver cancer deaths in people of ethnicities other than White and in the most deprived group were small in some years, leading to predicted rates with large uncertainties. Because of a small number of events, trends for gallbladder and endometrial cancer mortality rates are not shown but estimates are reported in ESM Table 8

Breast cancer mortality rates (Fig. 3a) increased slightly before decreasing in 55-, 65- and 75-year-olds and remained relatively stable in 85-year-olds, with AAPCs of 4.1% (95% CI 3.6, 4.7), –0.1% (–1.4, 1.2), –0.6% (–0.9, –0.3) and –0.5% (–0.5, –0.4), respectively (ESM Table 7). Prostate cancer mortality rates (Fig. 3f) increased in 75-year-olds (AAPC 0.8%; 0.6, 1.0) and 85-year-olds (5.6%; 5.5, 5.7) but decreased in 55-year-olds (–3.1%; –3.3, –2.8) and 65-year-olds (–1.2%; –1.4, –1.0) (ESM Table 7). Lung cancer mortality rates (Fig. 3k) increased slightly and then decreased for all age groups, with small increases from 1998 to 2018 in the two younger age groups (AAPCs 0.4% [0.2, 0.5] and 0.7% [0.6, 0.7] for 55- and 65-year-olds, respectively) and larger increases in the two older age groups (AAPCs 2.8% [2.5, 3.0] and 1.3% [1.1, 1.6] for 75- and 85-year-olds, respectively) (ESM Table 7). Except for those aged 75 years, colorectal cancer mortality rates (Fig. 3q) increased from 1998 to 2018 (AAPCs 3.1% [2.4, 3.9], 1.4% [1.2, 1.5], –0.5% [–0.7, –0.2] and 1.7% [1.6, 1.9] for 55-, 65-, 75- and 85-year-olds, respectively; ESM Table 7). Pancreatic cancer mortality rates (Fig. 4a) increased at all ages from 1998 to 2018 (AAPCs 2.0% [1.8, 2.2], 6.5% [6.0, 7.0], 2.6% [2.4, 2.9] and 6.1% [6.0, 6.3] for 55-, 65-, 75- and 85-year-olds, respectively; ESM Table 8). Steadily increasing trends were also observed for liver cancer mortality rates (Fig. 4g) at all ages (AAPC range 1.7–4.8%) and for endometrial cancer, except in the youngest age group (ESM Table 8).

Compared with women, men had higher lung, colorectal, pancreatic and liver cancer mortality rates but the gender gaps were smaller after 2010 and women had a higher colorectal cancer mortality rate than men after 2017 (Figs 3l,r, 4b,h; ESM Tables 7 and 8). We observed strong inequalities by socioeconomic status in lung cancer mortality rates, with markedly higher rates in the most deprived group (Fig. 3n). Lung cancer mortality rates were also higher in current smokers than in former or non-smokers (Fig. 3p), with increasing trends in current (AAPC 2.6%; 95% CI 1.9, 3.3) and former (5.7%; 5.5, 5.9) smokers and a decreasing trend in non-smokers (–11.0%; –11.1, –10.9) (ESM Table 7).

Standardised mortality ratios

SMRs for all-cause, all-cancer and cancer-specific mortality comparing those with type 2 diabetes with the general population were estimated for the whole study period and three stratified periods: 1998–2007, 2008–2012 and 2013–2018 (Table 4). Individuals with type 2 diabetes had higher rates of all-cause, all-cancer and colorectal, pancreatic, liver, breast and endometrial cancer mortality, with SMRs for the whole period ranging from 1.08 to 2.40.

Table 4 SMRs comparing those with type 2 diabetes with the corresponding sex-specific general population

SMRs for all-cause and all-cancer mortality increased and then levelled off after the 2008–2012 period, with SMRs of 1.01 (95% CI 0.99, 1.04) during 1998–2007, 1.19 (1.17, 1.21) during 2008–2012 and 1.17 (1.15, 1.19) during 2013–2018 for all-cause mortality; corresponding values for all-cancer mortality were 1.14 (1.09, 1.19), 1.26 (1.22, 1.30) and 1.21 (1.18, 1.24), respectively. SMRs for colorectal, pancreatic, liver and endometrial cancer mortality were consistently high (>1.5) during the whole study period, while there was no evidence of an association of type 2 diabetes with prostate cancer mortality (SMR 0.99; 0.92, 1.05). SMRs for all non-sex-specific cancers were higher in women than men except for liver cancer, for which men had a higher SMR than women during the whole study period.

Discussion

To a variable extent, we confirmed the previously reported [3, 4] reductions in all-cause mortality in people with type 2 diabetes among all age groups studied; conversely, all-cancer mortality rates declined in the younger age groups (<65 years) but increased in the older age groups, with increasing proportions of cancer deaths out of all-cause deaths in older people. Upward trends in all-cancer mortality rates were observed in both men and women, people of White ethnicity, in both the least and the most deprived quintiles and in people with normal weight and with severe obesity. With higher baseline rates but smaller increases in all-cancer mortality in men than women and in the most deprived group than the least deprived group, we still observed persistent inequalities by gender and deprivation. However, higher rates and increasing trends in current/former smokers than non-smokers led to widening disparities in both all-cause and all-cancer mortality rates by smoking status. Furthermore, there was evidence of constantly increasing trends in pancreatic, liver and lung cancer mortality rates at all ages; colorectal cancer mortality rates at most ages; breast cancer mortality rates at younger ages; and prostate and endometrial cancer mortality rates at older ages. Compared with the general population, people with type 2 diabetes had a more than 1.5-fold increased risk of colorectal, pancreatic, liver and endometrial cancer mortality.

Temporal variations in the definitions and ascertainment of populations and exposures may influence trend estimates in epidemiological studies. Changes in the quality of diabetes recording in the CPRD over time, possibly in relation to the implementation of the UK Quality and Outcomes Framework in 2004 [21], may have resulted in apparent variations in the characteristics of people with type 2 diabetes, with pre-existing complications and a higher mortality risk more commonly found during the initial years of the cohort. At the same time, the more proactive identification of cases of type 2 diabetes earlier in the trajectory of the disease, alongside changes in diagnostic criteria, the increasing incidence of early-onset type 2 diabetes [22] and the availability of newer glucose-lowering treatments with robust cardioprotective effects, may also have contributed to the pattern of a slight increase in all-cause and all-cancer mortality rates followed by declining trends [23, 24]. Furthermore, the reduced risk of fatal cardiovascular events and the resulting prolonged exposure to diabetes increases the likelihood of being diagnosed with conditions other than cardiovascular disease, including cancer; this may partly explain the overall increasing rates and proportions of cancer deaths over time in the older age groups [25]. Lastly, as is evident from improved cancer survival rates [26], early cancer detection and treatment may also have improved over time and this may disproportionally benefit certain subgroups of people with type 2 diabetes.

Our investigation has some strengths and limitations. First, we derived our cohort from electronic health records of primary care patients who were representative of the general population in England. However, these data are not collected for research purposes and the generalisability of our findings is limited by the characteristics of the included individuals and the potential differences in the healthcare system between the UK and other countries. Although we excluded individuals with type 1 diabetes and our clinical codes were reviewed by clinicians practising in England, misclassification was still possible. Second, to our knowledge this is the first study describing cancer-specific mortality trends by sociodemographic characteristics and risk factors in people with type 2 diabetes in England. Despite the large sample size, there were small numbers of deaths in some groups (e.g. across ethnicity), which prevented us carrying out precise and robust assessments of certain trends or investigating ethnic differences more granularly. Third, we used a modelling approach to estimate age-specific mortality rates to control for the impact of age and diabetes duration; indeed, the mean/median age of individuals with type 2 diabetes differs across countries (e.g. median of 58.5 years in a previous Australian study [27] vs 63.8 years in our study) and the overall trends across risk factors might simply reflect differences in the age composition or diabetes duration of the populations studied [28, 29]. Fourth, as our analyses are descriptive, they should not be interpreted as definitively indicating a causal relationship between sociodemographic characteristics or risk factors and cancer. For example, lung cancer mortality rates were higher in the most deprived group than the least deprived group and in smokers than non-smokers but deprivation and smoking status were not mutually adjusted for when estimating rates in these subgroups. In this respect, it is worth noting that removing the causal exposure associated with the higher cancer mortality rate results in a reduction in cancer-specific mortality rate but, at the same time, the risk of competing cause(s) of death may remain the same or even increase, potentially leading to a higher overall risk of death. Whether the magnitude of the effect for the same change in an exposure (e.g. most vs least deprived) differs across competing causes of deaths should be specifically explored in competing risk analyses. Fifth, many contextual factors, such as changes in timings and treatments of diabetes and/or cancer, may contribute to our observed trends but were not accounted for in our analyses. Finally, individuals with missing data on each factor were not included in the corresponding subgroup analysis but our results are unlikely to be strongly biased, given the small number of missing data (<10%) [30].

While declining trends in the rates of all-cause mortality among people with diabetes, mainly because of reduced vascular mortality rates [27, 28, 31, 32], have been consistently reported in the literature [4, 5, 27, 28, 31,32,33,34,35,36,37,38], the evidence is less clear for cancer, making a coherent understanding of the cancer burden in people with diabetes more difficult. Downward trends in cancer mortality rates have been observed in several studies [5, 27, 28, 31, 32, 34] while upward trends have been reported in Sweden and Taiwan [36, 37]; similarly, proportions of cancer deaths have remained stable in the USA [31, 33] but have increased in Australia and the UK [5, 39]. Notably, these studies estimated the overall rates or proportions, while we investigated age-specific rates and proportions of cancer deaths in more detail. In contrast to increasing trends in cancer mortality rates in young adults with type 2 diabetes reported in other countries [28, 29], we observed increasing trends only at older ages, with a parallel reduction in both rates and proportions of cancer deaths at younger ages (<65 years). Our findings also suggest a slightly increased SMR for cancer mortality, which stabilised over time at 1.2, in line with a previous systematic review with trend analysis [40]. While a similar analysis in Australia suggested initial reductions in SMRs for cancer mortality followed by stable trends, the SMRs also stabilised at approximately 1.2 in around 2010 [29, 39]. Taken together, our results confirm that the burden of cancer has increased in individuals with type 2 diabetes in England. At the same time, we found relevant differences across age groups, with such increases occurring mainly in older individuals.

Inequalities in cancer mortality rates by sociodemographic factors were persistent in our cohort. Consistent with previous findings from meta-analyses [12, 41, 42], in our study the SMRs for some cancers were higher in women than men; however, these results should be interpreted alongside the lower baseline cancer mortality rates in women than men. Moreover, in line with cancer mortality data in people with diabetes in the USA [43], we also observed a higher risk of cancer in people of White ethnicity than in people of other ethnicities and a higher risk in the most deprived group than in the least deprived group. However, in contrast to the stable gaps across ethnicity and deprivation observed in the same US study [43], we observed a narrowing then widening but persistent gap across ethnicity and socioeconomic status. These divergent findings may be related to differences between the two countries in social and healthcare systems and their reforms in the last two decades [44, 45] and in the measurement of socioeconomic status and classification of ethnicities. Of note, clinical coding of ethnicities has improved over time in the CPRD [46], which may also have influenced our results.

Few studies have reported cancer mortality rates by risk factors (i.e. smoking and obesity) in people with type 2 diabetes. Our results show that the cancer mortality rates in people with obesity were lower than those in people with normal weight at the start of the observation period, similar to the findings of a previous study carried out in the USA [43]. However, we also found a smaller increase in people with normal weight than in those with severe obesity, leading to similar rates between these two groups during the last years of observation. To our knowledge, this is the first study in people with type 2 diabetes showing constantly higher cancer mortality rates in current and former smokers than non-smokers, in parallel with a steady increase among smokers, leading to widening gaps in cancer mortality rates between smokers and non-smokers.

Our study has important clinical and public health implications. The prevention of cardiovascular disease has been, and is still considered, a priority in people with diabetes. Our results challenge this view by showing that cancer may have overtaken cardiovascular disease as a leading cause of death in people with type 2 diabetes. Cancer prevention strategies therefore deserve at least a similar level of attention as cardiovascular disease prevention [47], particularly in older people and for some cancers such as liver, colorectal and pancreatic cancer. Tailored interventions should also be considered for smokers, who had higher and steadily increasing cancer mortality rates. Early cancer detection through changes to existing screening programmes, or more in-depth investigations for suspected/non-specific symptoms [48], may reduce the number of avoidable cancer deaths in people with type 2 diabetes. From this perspective, our results suggest that it may be helpful to extend breast cancer screening to young women with type 2 diabetes. However, given the high cost and potentially longer exposure to screening procedures, cost-effectiveness analyses are required to define the appropriate time window and identify subgroups who may benefit more. Finally, the number of people with concurrent cancer and type 2 diabetes will be likely to increase in the future, highlighting the importance of improving multidisciplinary clinical management in these patients.

In conclusion, our findings underline the growing cancer burden in people with type 2 diabetes, particularly in older individuals, and highlight the need to prioritise cancer prevention, research and early detection and management in this population, especially for colorectal, pancreatic, liver and endometrial cancer, whose mortality rates were substantially higher in individuals with type 2 diabetes than in the general population. Persistent inequalities in cancer mortality rates by sociodemographic factors and widening disparities by smoking status suggest that tailored cancer prevention and detection strategies are needed. For example, some subgroups such as smokers experienced not only higher mortality rates but also increasing mortality trends during the study period.