Background. DNA methylation patterns associated with habitual diet have not been well studied.Methods and results. Diet quality was characterized using a Mediterranean-style diet score (MDS) and the Alternative Healthy Eating Index score (AHEI). We conducted ethnicity-specific and trans-ethnic epigenome-wide association analyses for diet quality and leukocyte-derived DNA methylation at over 400,000 cytosine-guanine dinucleotides (CpGs) in five population-based cohorts including 6,662 European ancestry (EA), 2,702 African ancestry (AA), and 360 Hispanic ancestry (HA) participants. For diet-associated CpGs identified in epigenome-wide analyses, we conducted Mendelian randomization (MR) analysis to examine their relations to cardiovascular disease (CVD) risk factors and examined their longitudinal associations with all-cause mortality. We identified 30 CpGs associated with either MDS or AHEI, or both, in EA participants. Among these CpGs, 12 CpGs were significantly associated with all-cause mortality (Bonferroni corrected p-value < 1.6×10-3). Hypermethylation of cg18181703 (SOCS3) was associated with higher scores of both MDS and AHEI and lower risk for all-cause mortality (p-value = 5.7×10-15). Ten additional diet-associated CpGs were nominally associated with all-cause mortality (p-value < 0.05). MR analysis revealed eight putatively causal associations for six CpGs with four CVD risk factors (BMI, triglycerides, high-density lipoprotein cholesterol concentrations, and type 2 diabetes; Bonferroni corrected MR p-value < 4.5×10-4). For example, hypermethylation of cg11250194 (FADS2) was associated with lower triglyceride concentrations (MR p-value = 1.5×10-14).and hypermethylation of cg02079413 (SNORA54; NAP1L4) was associated with BMI (corrected MR p-value = 1×10-6). Ten additional CpGs were associated with either MDS or AHEI at a false discovery rate <0.05 in trans-ethnic meta-analysis.Conclusions. Habitual diet quality was associated with differential peripheral leukocyte DNA methylation levels of 30 CpGs, most of which were also associated with multiple health outcomes, in EA individuals. These findings demonstrate that integrative genomic analysis of dietary information may reveal molecular targets for disease prevention and treatment.