Background: Previous studies on dietary magnesium and risk of ischemic heart disease (IHD) have yielded inconsistent results, in part because of a lack of direct measures of actual magnesium uptake. Urinary excretion of magnesium, an indicator of dietary magnesium uptake, might provide more consistent results. Objective: The objective was to investigate whether urinary magnesium excretion and plasma magnesium are associated with IHD risk. Design: We examined 7664 adult participants free of known cardiovascular disease in the Prevention of Renal and Vascular EndStage Disease (PREVEND) study-a prospective population-based cohort study. Urinary magnesium excretion was measured in 2 baseline 24-h urine collections. Results: Mean 6 SD urinary magnesium excretion was 4.24 6 1.65 mmol/24 h for men and 3.54 6 1.40 mmol/24 h for women. During a median follow-up of 10.5 y (IQR: 9.9-10.8 y), 462 fatal and nonfatal IHD events occurred. After multivariable adjustment, urinary magnesium excretion had a nonlinear relation with IHD risk (P-curvature = 0.01). The lowest sex-specific quintile (men: ,2.93 mmol/24 h; women: ,2.45 mmol/24 h) had an increased risk of fatal and nonfatal IHD (multivariable HR: 1.60; 95% CI: 1.28, 2.00) compared with the upper 4 quintiles of urinary magnesium excretion. A similar increase in risk of the lowest quintile was observed for mortality related to IHD (HR: 1.70; 95% CI: 1.10, 2.61). No associations were observed between circulating magnesium and risk of IHD. Conclusions: Low urinary magnesium excretion was independently associated with a higher risk of IHD incidence. An increased dietary intake of magnesium, particularly in those with the lowest urinary magnesium, could reduce the risk of IHD.