Does Magnesium Help You Sleep?

We receive free products to review and participate in affiliate programs. See our disclosure page for more information.

[Editor’s Note: The content provided on this site is for general informational purposes only. Any information provided is not a substitute for professional medical advice. We encourage you to consult with the appropriate health expert if you have concerns.]

Sleep is important to every aspect of your health, and magnesium is often touted as a great sleep aid. Is it? Read on to find out how this mineral may help you relax more and get better ZZZs.

What Is Magnesium?

Most adults have about 25 grams of magnesium in their body. It is an essential mineral for health that relaxes muscles after contraction. The body stores most magnesium in the bones, which means blood tests for magnesium don’t always give the full picture of your magnesium levels.

A woman rests on her side on the Emma mattress

It’s possible to have both too much and too little magnesium in your body. A level that is a little high or a little low may not cause any symptoms. If you have an extremely high level of magnesium (hypermagnesemia), you may experience symptoms like weakness, lethargy, low blood pressure, low heart rate, nausea, vomiting, or flushed skin.

If you have an extremely low level of magnesium (hypomagnesemia), you may experience seizures, nausea, vomiting, diarrhea, high blood pressure, changes to heart rhythm, and/or muscle tremors. It can also disrupt your sleep, create headaches, and cause irritability.

Health Benefits of Magnesium

Magnesium offers a host of benefits to our bodies, from bone formation to stress reduction.

Heart Health Support

Magnesium can relax heart vessels much like it eases tension in other areas of the body. Some studies have shown a correlation between high magnesium levels and lower risk of heart disease.

Bone Formation and Density

Magnesium is important for healthy bones, and in general, people who have more magnesium have a higher bone density. This can help reduce the risk of bone fractures and osteoporosis

Stress Reduction

Chronic stress can lead to many serious health issues. Our body produces many chemicals as part of the stress response, such as norepinephrine, cortisol, and serotonin. Results from numerous studies show that magnesium plays a role in regulating these chemicals.

A stressed man rubs his head

Foods with Magnesium

Good food sources of magnesium include:

  • nuts
  • green leafy vegetables
  • cocoa
  • brown rice
  • peanuts
  • spinach
  • mackerel
  • whole wheat bread
  • avocado
  • buckwheat

If you’re concerned about getting too much magnesium from food, don’t be. It is almost impossible to do so. In fact, the typical western diet makes it challenging to get enough magnesium from food due to processed foods and magnesium-poor soils.

What to Look for in Your Magnesium Supplement

There are many different magnesium supplements on the shelves, and they’re not all the same.  So how do you know which type you need?

Magnesium Glycinate

Magnesium glycinate is a combination of magnesium and glycine, an amino acid. Glycine is a nonessential amino acid, which means your body makes it and therefore it’s not necessary to get from food. By itself, glycine can improve sleep quality, reduce insomnia, and ease anxiety symptoms.

Magnesium Citrate

Magnesium citrate is magnesium and citric acid, an acid found in fruits that is responsible for their slightly sour or tart flavor. Studies have shown that this form has both high and low bioavailability, so more research is needed. Magnesium citrate not only helps increase low magnesium levels – it can also help with constipation.

Magnesium Malate

Research suggests that magnesium malate may be one of the easiest forms of magnesium to use by your body. This makes it well suited to generally raise magnesium levels. It also has less of a laxative effect than other forms. Many doctors recommend magnesium malate for people suffering from fibromyalgia and chronic fatigue.

Vitamin D3

Magnesium and Vitamin D work together synergistically in the body. Magnesium activates Vitamin D, and Vitamin D increases magnesium absorption. Through unknown mechanisms, Vitamin D can also help improve the length and quality of sleep.


Zinc may also be beneficial for strengthening the immune system. However, some studies have found that a zinc intake of 53-142 mg per day can interfere with magnesium absorption.

What to Avoid in Magnesium Supplements

If you’re looking to use magnesium to increase sleep quality, there are a few things you may want to avoid.

Magnesium Oxide

Magnesium oxide is used as an antacid or laxative. It works by pulling more water out of the intestine and into the stool to make it easier to poop. For either antacid or laxative use, you shouldn’t take magnesium longer than 1-2 weeks. Consult your doctor if you’re taking magnesium oxide with another magnesium supplement; they can help you find a safe dosage for your needs.

Added Calcium

Calcium and magnesium have opposite effects on the body, so if you are trying to increase the effects of magnesium, you probably don’t want to be increasing calcium as well. Magnesium relaxes muscles after contraction, while calcium causes contraction; also, very high calcium intake can reduce the absorption of magnesium.

Fillers and Additives

Some supplements may contain additives or fillers to offset color loss from processing or add bulk. Some you might want to avoid include artificial colors, hydrogenated oils, talc, and titanium dioxide.

does magnesium help you sleep?

Does Magnesium Help You Sleep?

Studies suggest magnesium can help people get adequate sleep – about 7-8 hours a night. Magnesium is also correlated with production of melatonin, a key hormone in the sleep-wake cycle.

Magnesium for Insomnia

There is a reason people spend a third of their lives sleeping — it is critical for every aspect of health. Insomnia is a sleep disorder that makes it difficult or impossible for sufferers to sleep through the night. Studies have found that magnesium amplifies effects of GABA and blocks effects of NMDA in the body. Both these actions promote relaxation and facilitate sleep.

Magnesium for Restless Leg Syndrome

People with restless legs syndrome often feel tingling, crawling sensations across their legs, which creates the urge to move them. Symptoms are usually worse when trying to sleep or relax. Studies show that magnesium supplementation can significantly decrease leg movements during sleep.

Magnesium vs Melatonin

Magnesium and melatonin are both important regulators of sleep, but with some different considerations.

Melatonin is a hormone that the brain makes at night. It helps your body relax into sleep. If your brain is exposed to light during normal sleeping hours at night – ie, working third shift or staring at a screen way too late – then it won’t produce melatonin. Melatonin is an anti-inflammatory, and it is not found in food. If you want to increase your melatonin levels, your only option is to use supplements. Currently, the American Academy of Sleep Medicine (2017) and the American College of Physicians (2016) support melatonin use for short periods of time, but not for chronic insomnia.

A man sleeps on his stomach while using the Plushbeds Goose Down Pillow.

Magnesium is not produced in the body, and therefore needs to be ingested via food or supplements. Magnesium has been proven safe for long-term use via many studies; on the other hand, there is no conclusive evidence on the safety of long-term melatonin use yet.

Magnesium and melatonin can both interact with other medications, so always consult with your healthcare provider before adding either to your routine.

When to Take Magnesium for Sleep

Working magnesium into a regular bedtime ritual can help it be effective. Integrative medicine specialist Naoki Umeda, MD recommends taking magnesium supplements about 30  minutes before bedtime to allow time for them to take effect.


How much magnesium should I take?

A good step to start with is having bloodwork done. While the reference range differs slightly depending on the source, the normal range for magnesium is 1.5 - 3.1 mmol/L. Remember that most magnesium is stored in the bones, not the blood. So if you are experiencing symptoms of low magnesium levels even though your blood levels are normal, you might still benefit from magnesium supplements.

According to the Institute of Medicine (IOM) the upper tolerable limit of magnesium supplementation with no side effects is 350 mg/day. However, always consult with your healthcare provider to determine the appropriate dosage.

Can you take too much magnesium?

Yes, it is possible to take too much magnesium. Hypermagnesemia, or having too much magnesium in your blood, can cause serious health problems.

Does magnesium lower blood pressure?

Results on whether magnesium lowers blood pressure are inconclusive. Some studies show it does not significantly change blood pressure, while other studies conclude that it may.

Is magnesium safe during pregnancy?

Magnesium is generally regarded as safe during pregnancy.  In fact, it is often used when a pregnant person has dangerously high blood pressure. Magnesium needs during pregnancy and lactation increase by about 10%. The recommended daily allowance is 350–400 mg/day during pregnancy.

Final Thoughts

Magnesium is a mineral critical for our health. If you’re having trouble sleeping, a magnesium imbalance could be a cause. It’s essential to collaborate with a trained healthcare provider to determine if supplementation is needed as well as what type and how much to incorporate into your diet and supplement regime. Once magnesium reaches optimal levels in your body, you could be on your way to some sweet dreams.

Jessie Gellings

Jessie Gellings is a freelance writer, registered nurse, and student of the American Medical Writers Association.  She specializes in supporting women-led, health-focused organizations. When she's not writing, you'll find Jessie wandering in wild places, singing, and cooking.