Start free

KnowledgeSupplements

Does magnesium help with sleep and muscle cramps?

For cramps the best evidence points to little or no effect. For sleep it is thin and mixed, with perhaps a slightly faster time to fall asleep but little beyond that. Magnesium matters most if you are genuinely low on it.

Limited evidenceHow we grade evidence

What the research says

The question bundles two different things, and the evidence differs. For muscle cramps the picture is fairly clear. The Cochrane review by Garrison and colleagues pooled eleven trials with 735 people in total and found that magnesium barely moves ordinary calf cramps in adults. The difference came to about a fifth of a cramp fewer per week, which was not statistically significant, and neither intensity nor duration changed. Their conclusion was that magnesium is unlikely to offer any meaningful benefit against cramps. For pregnancy-related cramps the trials were too inconsistent to combine.

For sleep the evidence is thinner. Mah and Pitre pooled three randomised trials totalling 151 older adults. Those given magnesium fell asleep about seventeen minutes faster on average, but total sleep time did not reliably increase, and the authors stressed that the trials were small and of low to very low quality. Observational data add another piece: in the CARDIA study, which followed nearly four thousand adults over several years, a higher total magnesium intake (diet and supplements combined) was linked to lower odds of short sleep, while the link to better self-rated sleep quality was only borderline and did not reach statistical significance. That is still observational data, not a trial, so correlation isn't the same as causation here. The thread running through it all: magnesium matters most when you are genuinely running low.

Why the myth exists

Magnesium has become the go-to cure-all for sleep and wellness accounts, and several things feed that. The supplement is cheap, feels natural and carries almost no risk, which makes it easy to recommend and hard to argue against. Taking a tablet before bed becomes a ritual, a sense of doing something about your sleep, and the ritual itself can settle you. The correlation is also easily mistaken for cause: someone who sleeps badly and runs stressed often eats worse and may sit lower in magnesium, so the mineral gets both the blame and the credit at once. On top of that sits a large supplement market that profits from selling the fix, plus a body of research where low status in some people has been inflated into everyone needing to top up.

What it means for you

If you sleep poorly or get cramps, magnesium is cheap and safe to try, but keep your expectations low; it is not a fix for either. For sleep, regular times, daylight and earlier caffeine do more. For cramps, fluids and stretching usually help more. The easiest source is food: nuts, whole grains, legumes and leafy greens. Recurring cramps or persistent sleep trouble can point to something else, so take it up with your healthcare provider rather than guessing your way through supplements.

Sources

  1. Magnesium for skeletal muscle cramps (Garrison et al., Cochrane Database of Systematic Reviews)2020 · Systematic review · doi:10.1002/14651858.CD009402.pub3
  2. Oral magnesium supplementation for insomnia in older adults: a Systematic Review & Meta-Analysis (Mah & Pitre, BMC Complementary Medicine and Therapies)2021 · Meta-analysis · doi:10.1186/s12906-021-03297-z
  3. Association of magnesium intake with sleep duration and sleep quality: findings from the CARDIA study (Zhang et al., Sleep)2022 · Cohort study · doi:10.1093/sleep/zsab276

Related claims

kaliba is guidance built on nutrition science, not medical advice. 18+.