NutriSeek

Can low magnesium cause vitamin D deficiency?

General nutrition researchAnswered by NutriSeek AI · November 8, 2026

Low magnesium may make vitamin D less effective, and could contribute to low vitamin D levels, but it is not a proven direct cause of deficiency. Magnesium helps the body convert vitamin D into its active form, so a shortfall can get in the way. The evidence is promising but still developing.

How magnesium and vitamin D are linked

Vitamin D from sunlight or food is inactive until the body changes it in two steps, in the liver and then the kidneys. Several of the enzymes (proteins that speed up chemical reactions) involved in this process need magnesium to work. Magnesium also helps vitamin D travel in the blood.

What the research generally shows:

  • Observational studies (which track what people already do) find that people with higher magnesium intake are less likely to have low vitamin D, and that magnesium may amplify the effect of vitamin D supplements.
  • Small trials suggest magnesium supplements can nudge vitamin D levels toward the normal range, with the biggest changes in people who started out very low or very high.
  • What's unsettled: these studies can't prove cause and effect, and the effect sizes are modest. Low vitamin D is far more often explained by little sun exposure, darker skin, northern latitudes, older age, or limited dietary vitamin D.

So it's best to think of magnesium as one supporting factor, not the main cause.

Food sources of magnesium

Here are some foods from the USDA data, per 100 g (adult daily targets are roughly 310-420 mg, depending on age and sex):

Food Magnesium (per 100 g) Per typical serving
Pumpkin seeds, dried kernels 592 mg about 764 mg per 1 cup (129 g)
Almonds 270 mg about 76 mg per 1 oz (28 g)
Salmon, Atlantic, farmed, raw 27 mg about 23 mg per 3 oz (85 g)
White mushrooms, raw 9 mg about 6 mg per 1 cup (70 g)

Serving amounts are calculated from the USDA per-100 g figures. Pumpkin seeds and almonds are the standouts, though a full cup of pumpkin seeds is far more than most people would eat in one sitting; a small handful is more realistic.

Food sources of vitamin D

Farmed Atlantic salmon provides 11 µg (micrograms) of vitamin D per 100 g, according to USDA, or about 9 µg in a 3 oz serving. Raw white mushrooms have only 0.2 µg per 100 g, though mushrooms exposed to UV light can contain much more. Nuts and seeds contain essentially none. Salmon is a useful pairing because it supplies vitamin D along with a modest amount of magnesium.

Practical takeaways

  • Eating magnesium-rich foods regularly is a sensible, low-risk way to support healthy vitamin D metabolism.
  • If you have been told your vitamin D is low, or you're considering magnesium supplements, check with a doctor, pharmacist, or registered dietitian. High-dose supplemental magnesium can cause diarrhea, and people with kidney disease, or those taking certain medications (some antibiotics, bisphosphonates, and diuretics), need particular care.
  • A blood test is the only way to know your vitamin D status, and a professional can help work out whether diet, sunlight, or supplements make the most sense for you.

Further reading from the NIH

Ask next

More in this topic

Absorption & Interactions

Foods in this answer

Full nutrition facts