Magnesium

Does magnesium help you sleep and reduce stress?

Magnesium may improve sleep and ease anxiety, especially in older adults or people with low intake, but large trials are lacking.

Magnesium plays a direct role in helping your body wind down. It activates the parasympathetic nervous system, the part responsible for calming you down, and it helps regulate melatonin, the hormone that guides your sleep-wake cycle4. Observational studies have found an association between magnesium status and sleep quality5, and in one large Chinese study women with the highest magnesium intake were less likely to fall asleep during the day3. If you often feel tense, restless at night, or experience muscle cramps, low magnesium could be a contributing factor1.

What you can do

  • Check whether your diet is low in magnesium first; benefits were clearest in people with low intake or status2,5.
  • If you are tense, restless at night or get muscle cramps, ask your doctor whether low magnesium could be a factor1.
  • Judge any change over weeks, not days: the sleep trial lasted eight weeks1.

Be careful if

  • Benefits were most consistent in older adults and people with low magnesium intake; results in others are less certain5.
  • Not a substitute for medical care if insomnia, anxiety or muscle cramps persist.
How it works What it does in your body, in plain words 2 min

Magnesium influences sleep and stress through several interconnected mechanisms. It acts as a natural NMDA receptor antagonist and a GABA agonist, meaning it quiets excitatory neural signaling while enhancing the brain's primary inhibitory neurotransmitter4. This dual action helps explain why magnesium has both anxiolytic and sedative properties.

A double-blind, placebo-controlled trial in elderly subjects with insomnia found that 500 mg of magnesium daily for eight weeks significantly improved subjective sleep quality, sleep time, sleep onset latency, and early morning awakening compared to placebo1. Serum melatonin and serum renin levels also increased in the magnesium group, while serum cortisol decreased, suggesting that magnesium modulates the hormonal axes governing both circadian rhythm and stress response1.

Population-level data point in a similar direction, though the outcome measured differs. Cao et al. (2018) analyzed data from 1,487 Chinese adults in the Jiangsu Nutrition Study: dietary magnesium was assessed with 3-day weighed food records in 2002, and sleep disorder symptoms (daytime falling asleep, daytime sleepiness and snoring at night) were gathered with a questionnaire in 2007. Compared with the lowest quartile of magnesium intake, the highest quartile was associated with a lower likelihood of daytime falling asleep in women but not in men, and no associations were found with daytime sleepiness or night snoring in either sex3.

On the anxiety side, a systematic review by Boyle, Lawton, and Dye (2017) examined 18 studies and found suggestive evidence that magnesium supplementation may reduce subjective anxiety in vulnerable populations, including those with premenstrual syndrome, postpartum anxiety, and generalized mild anxiety2. They noted that effects were more consistent when baseline magnesium status was low2.

Magnesium also directly reduces muscle tension by competing with calcium at the neuromuscular junction. Where calcium triggers contraction, magnesium promotes relaxation, which is why deficiency often manifests as cramps, spasms, and restless legs4.

The evidence The studies, what they found, and how much to trust them 2 min · 5 sources

Abbasi et al. (2012) conducted one of the most cited clinical trials on magnesium and sleep1. In this randomized, double-blind, placebo-controlled study, 46 elderly subjects with insomnia received either 500 mg elemental magnesium (as magnesium oxide) or placebo daily for eight weeks. The magnesium group showed statistically significant improvements across all measured outcomes: Insomnia Severity Index scores dropped by an average of 6.4 points (vs. 1.7 in placebo), sleep efficiency increased, and sleep onset latency decreased1. Biomarker changes were equally notable. Serum melatonin increased, serum cortisol decreased, and serum renin (a marker of sympathetic nervous system activity during sleep) increased, collectively suggesting that magnesium restores the hormonal environment needed for healthy sleep architecture1.

Arab et al. (2023) conducted a systematic review of the available literature on magnesium and sleep health, encompassing both observational and interventional studies5. They concluded that magnesium supplementation appears to improve subjective sleep quality measures, though they called for more large-scale RCTs with standardized dosing and sleep assessment tools to strengthen the evidence base5. The most consistent benefits appeared in older adults and those with documented low magnesium intake.

Boyle, Lawton, and Dye (2017) performed a systematic review of magnesium supplementation for anxiety and stress across 18 studies of varying design2. While acknowledging methodological heterogeneity, they found that the available evidence "suggests a beneficial effect of magnesium on subjective anxiety" in populations with mild to moderate anxiety symptoms2. Effects were most robust in studies where participants had lower baseline magnesium, supporting the hypothesis that supplementation corrects a functional deficit rather than producing a pharmacological effect2.

Kirkland, Sarlo, and Holton (2018) synthesized the neurobiological mechanisms in their review "Magnesium and the Brain: The Original Chill Pill"4. They detailed how magnesium blocks the NMDA receptor ion channel in a voltage-dependent manner, reducing excitatory glutamate signaling, while simultaneously potentiating GABAergic inhibition4. They also reviewed evidence that magnesium deficiency upregulates the hypothalamic-pituitary-adrenal (HPA) axis, increasing cortisol and catecholamine release, which creates a neurochemical environment of chronic low-grade stress4. Restoring adequate magnesium levels normalizes HPA axis function and reduces the inflammatory cytokines (IL-6, TNF-alpha) associated with both stress and sleep disruption4.

  1. The effect of magnesium supplementation on primary insomnia in elderly: A double-blind placebo-controlled clinical trial. Abbasi B, Kimiagar M, Sadeghniiat K, Shirazi MM, Hedayati M, Rashidkhani B. Journal of Research in Medical Sciences, 2012. PubMed 23853635
  2. The effects of magnesium supplementation on subjective anxiety and stress — a systematic review. Boyle NB, Lawton C, Dye L. Nutrients, 2017. PubMed 28445426
  3. Magnesium Intake and Sleep Disorder Symptoms: Findings from the Jiangsu Nutrition Study of Chinese Adults at Five-Year Follow-Up. Cao Y, Zhen S, Taylor AW, Appleton S, Atlantis E, Shi Z. Nutrients, 2018. PubMed 30248967
  4. The Role of Magnesium in Neurological Disorders. Kirkland AE, Sarlo GL, Holton KF. Nutrients, 2018. PubMed 29882776
  5. The role of magnesium in sleep health: a systematic review of available literature. Arab A, Rafie N, Amani R, Shirani F. Biological Trace Element Research, 2023. PubMed 35184264

Every change to this page is tracked in version control. View edit history. If you have conflicting research, we want to hear about it.

Spotted something wrong or out of date? Suggest a change.

Weekly research digest

New topics and updated research, once a week when there's something new. How it works