Skip to content
MyFreud

Magnesium for Sleep: What the Studies Show

Does magnesium help you sleep? What a review of three trials in 151 older adults and a nine-study review found on falling asleep, sleep time and safety.

6 min read

Pop-art illustration of a woman with dark hair pulled back, asleep on her side in bed with her cheek resting on her hand and an orange pillow, a window with a pale curtain behind her.

Key takeaways

  • A 2021 systematic review pooled three trials of 151 older adults and found that people fell asleep 17.36 minutes sooner on oral magnesium than on placebo (95% confidence interval 7.44 to 27.27 minutes sooner).
  • Total sleep time was 16.06 minutes longer with magnesium, but that difference was statistically insignificant, all three trials were at moderate-to-high risk of bias, and the evidence was rated low to very low quality.
  • A separate systematic review of 9 studies and 7,582 people found that observational studies linked magnesium status with sleep quality, while randomised trials showed an uncertain association between magnesium supplements and sleep disorders.
  • Both reviews call for better-designed trials, and the nine-study review asks for follow-up longer than 12 weeks, so what dose helps, for whom and for how long is still open.
  • These are averages from small trials in older adults, so they cannot tell you whether magnesium will help your sleep, and they are no substitute for advice from a doctor or pharmacist who knows your other medicines.

Magnesium may help older adults fall asleep a little sooner, but the evidence is weak and rests on three small trials. A 2021 systematic review found people fell asleep 17.36 minutes sooner on oral magnesium than on placebo, from trials at moderate-to-high risk of bias, [mah-2021] and a systematic review of nine studies found that observational studies linked magnesium status with sleep quality while randomised trials gave contradictory results. [arab-2023] This guide covers what both reviews found, what they could not show and what to ask a doctor or pharmacist. Our sleep overview covers the wider picture, and our guide to melatonin for sleep covers the other supplement people most often ask about.

Does magnesium help you sleep?

Possibly a little, but the evidence is too weak to be sure. The best case for it is a 2021 pooled analysis of three randomised trials in older adults, in which people on magnesium fell asleep sooner than people on placebo. [mah-2021] The wider evidence is less encouraging: a review of nine studies found that randomised trials showed an uncertain association between magnesium supplementation and sleep disorders. [arab-2023]

The reviewers were guarded themselves. The 2021 authors wrote that the quality of the literature is substandard for doctors to make well-informed recommendations on oral magnesium for older adults with insomnia, while noting that, because it is cheap and widely available, the trial evidence may support supplements of less than 1 g given up to three times a day. [mah-2021]

What did the trials in older adults find?

People fell asleep sooner, and that is the only result that held up statistically. The 2021 review pooled three randomised trials of 151 older adults (most aged 55 or over) in three countries, each comparing oral magnesium with placebo. Falling asleep took 17.36 minutes less after magnesium (95% confidence interval 7.44 to 27.27 minutes less). Total sleep time was 16.06 minutes longer, but that difference was statistically insignificant. [mah-2021]

In older adults, magnesium was followed by falling asleep about 17 minutes sooner, but the extra sleep time was not statistically reliable Reported figures
0 5 10 15 20 Minutes better than placebo 17.36 Fell asleep sooner 16.06 Slept longer (not statistically reliable)

Pooled results from the systematic review by Mah and Pitre (2021): three randomised trials, 151 older adults. Sleep onset latency was 17.36 minutes shorter (95% confidence interval 7.44 to 27.27); total sleep time was 16.06 minutes longer (95% confidence interval from 5.99 minutes shorter to 38.12 minutes longer, which includes no difference).

The trials gave daily elemental magnesium of 320 mg to 729 mg, taken two to three times a day as magnesium oxide or magnesium citrate tablets, and followed people for 20 days to 8 weeks. Sleep questionnaires were less clear: one trial reported a greater improvement on the Insomnia Severity Index with magnesium, while another found equal improvement on the Pittsburgh Sleep Quality Index in both groups. [mah-2021]

The quality of those trials is the main reason to be cautious. All three were at moderate-to-high risk of bias, none reported how people were randomised, allocated or blinded despite being called double-blind, and the authors rated the evidence for every outcome as low to very low quality. [mah-2021]

What did the wider review of nine studies find?

Observational studies tied magnesium to sleep, but randomised trials did not agree. The review searched PubMed, Scopus and Web of Science up to November 2021 and included 9 cross-sectional, cohort and randomised studies with 7,582 people. Observational studies suggested an association between magnesium status and sleep quality (daytime falling asleep, sleepiness, snoring and sleep duration), while the randomised trials showed an uncertain association between magnesium supplementation and sleep disorders. [arab-2023]

An association in observational data cannot show that adding a supplement changes sleep, because people with different magnesium status may differ in many other ways. That is our reading of why the two kinds of study point different ways, and it is why the review asks for larger, well-designed trials with follow-up of more than 12 weeks. [arab-2023]

Is magnesium safe for sleep?

The reviews give only part of an answer. The 2021 review had no data on adverse events in its summary of findings. One trial reported that all participants had soft stools, which the authors describe as a known side-effect of oral magnesium, and the other trials did not report any unintended adverse effects. [mah-2021]

The trials lasted 20 days to 8 weeks, so nothing here covers taking magnesium for months or years. [mah-2021] Whether a supplement suits you depends on your health and your other medicines, which is a question for a doctor or pharmacist.

QuestionWhat the reviews foundCaveat
Fall asleep sooner?17.36 minutes sooner than placebo (3 trials, 151 older adults)Moderate-to-high risk of bias
Sleep longer?16.06 minutes longer, statistically insignificantSame three trials
Sleep questionnaires?One trial improved, one equal to placeboMixed result
Wider evidence?Observational links; randomised trials contradictory (9 studies)Observational studies cannot show cause
Side-effects?Soft stools in one trial; no pooled adverse-event dataTrials ran 20 days to 8 weeks

What can this research not show?

It cannot show whether magnesium will help you, at what dose or for how long. Five limits matter most:

  • It says little about younger adults. The three trials were in older adults, and the wider review’s randomised trials gave contradictory results. [mah-2021] [arab-2023]
  • The trials were small and at risk of bias. Three trials, 151 people, and none described how people were randomised or blinded. [mah-2021]
  • The long term is uncovered. The trials ran 20 days to 8 weeks, and the nine-study review asks for follow-up beyond 12 weeks. [mah-2021] [arab-2023]
  • The right dose is unknown. The trials used a wide range of daily doses, and the authors call for more rigorous studies. [mah-2021]
  • Magnesium was not compared with other treatments. Neither review set it against talking therapy for insomnia, melatonin or sleeping pills.

What should you ask a doctor or pharmacist?

Ask whether a magnesium supplement is sensible with your other medicines, which form and dose they would suggest, how long to try it before judging it, and what to do if it does not help. This section is our suggestion and is not something the reviews tested.

Our guides to sleep hygiene, CBT for insomnia and sleeping pills cover the other routes, and why you cannot sleep covers common causes. If you want a rough picture of how much sleep is affecting you before an appointment, our insomnia screener, built on the Insomnia Severity Index, is a short self-check. It is not a diagnosis, and it does not tell you whether magnesium is right for you.

When to seek help

Speak to a doctor if poor sleep has lasted three weeks or more, if it is affecting your days or mood, or if you have a long-term health condition or take regular medicines and are thinking about a supplement. If you feel unable to stay safe, contact your local emergency services or a crisis helpline.

How MyFreud can help

A sleep record helps a doctor more than a description from memory. Daily mood tracking in MyFreud shows how your days run over weeks, and the notepad is somewhere to note when you slept, what you took and how you felt the next day. It does not replace a doctor or a pharmacist.

Download MyFreud and start today: App Store or Google Play.

Frequently asked questions

Does magnesium help you sleep?

Possibly a little, but the evidence is weak. A 2021 review of three trials in 151 older adults found people fell asleep about 17 minutes sooner on magnesium than on placebo, yet all three trials were at moderate-to-high risk of bias and the evidence was low to very low quality. A broader review of nine studies found that randomised trials gave an uncertain picture.

How much magnesium should you take for sleep?

The research we could verify does not settle it. The trials in the 2021 review gave daily elemental magnesium of 320 mg to 729 mg, taken two to three times a day as magnesium oxide or magnesium citrate tablets, and the authors said the evidence may support supplements of less than 1 g given up to three times a day. That describes what was studied in older adults, so ask a doctor or pharmacist about a dose for you.

Is it safe to take magnesium every night?

The reviews cannot say. The 2021 review had no data on adverse events in its summary of findings; one trial reported soft stools in all participants and the others did not report unintended adverse effects. The trials ran for 20 days to 8 weeks, so long-term use was not covered.

Is magnesium better than melatonin or sleeping pills?

The research here cannot rank them, because neither review compared magnesium with melatonin or sleeping pills. Each has its own evidence and limits, which our guides to melatonin and sleeping pills set out.

Does magnesium work for younger adults?

The 2021 trials were in older adults, most aged 55 or over, so they cannot say. The nine-study review covered adults more widely, and its randomised trials gave contradictory findings, so there is no clear answer for younger adults either.

References

  1. 1.Mah J, Pitre T ( 2021). Oral magnesium supplementation for insomnia in older adults: a systematic review & meta-analysis. BMC Complementary Medicine and Therapies. doi.org . doi:10.1186/s12906-021-03297-z
  2. 2.Arab A, Rafie N, Amani R, Shirani F ( 2023). The role of magnesium in sleep health: a systematic review of available literature. Biological Trace Element Research. doi.org . doi:10.1007/s12011-022-03162-1