Immune-mediated diseases in whole were associated with increased risk of ACD (HR, 1.10; 95% CI, 1.00–1.21) and VD (HR, 1.43; 95% CI, 1.19–1.73) while not associated with AD after multivariable adjustment for age, sex, education, ApoE-ε4, ethnicity, BMI, Townsend deprivation score, smoking, and alcohol consumption (Fig. 1 and Supplementary Table 4). Here, APOE is linked to Alzheimer disease.