Can magnesium *actually* help you sleep? Here’s what we know

Clinically reviewed by Dr. Chris Mosunic, PhD, RD, MBA
When you're desperate for a good night's sleep, you'd likely do anything to help. But is magnesium the answer? Here's what you need to know.
Some days you do everything right. You avoid caffeine all day, you meditate, you get a good workout in, and you set your bedroom up for the ideal sleep conditions. You’ve got the white noise machine going, you stayed off your phone and yet—after all that—you still can’t fall asleep.
In moments like this, frustration can be overwhelming. Other than thinking that the world’s incredibly unfair, you’re probably also dying to know if there’s anything out there that can actually help you get to sleep naturally.
Supplements like magnesium glycinate have become the buzzworthy topic in the wellness world because they’re supposedly the ultimate relaxation mineral. It’s suggested that they can naturally help to calm your mind and your body. But is magnesium really the savior the wellness world is touting?
Does magnesium help with sleep?
The internet will tell you that while magnesium isn’t a cure-all for sleep issues, it can be a powerful tool to help you get the rest you need. But we’re here to tell you that it’s not that simple.
While magnesium is an essential mineral, that doesn’t necessarily mean it can help calm your nervous system and prepare you for sleep. In most cases, magnesium is only helpful for sleep with people or communities that are magnesium deficient.
Anytime the body is balanced with the correct levels of vitamins, minerals, and hydration, it will function better. So, if someone is magnesium deficient, solving that imbalance may promote better overall wellbeing, including better sleep.
If your magnesium levels are balanced and you’re dealing with chronic sleep issues like insomnia or even restless leg syndrome, there’s likely a multitude of other factors involved, and for that reason, there’s no one-size-fits all solution. Anything you use to try to help you get better rest should always be used in tandem with other sleep hygiene practices. You should also chat with your healthcare provider before trying out supplements.
Studies on the link between magnesium and sleep
Some people suggest that magnesium can help promote relaxation, making it easier to fall asleep. Or that magnesium could be helpful for people with mild to moderate anxiety, because it can calm the mind, reduce racing thoughts, and improve overall sleep quality.
We wish we could tout this as good news for anxious and stressed folks, but it’s important to note that a 2021 meta-analysis found inconsistent results regarding magnesium’s effectiveness for sleep.
While some participants reported improvements, others showed no significant difference compared to placebo groups. The study suggested that magnesium may be more beneficial for specific groups—such as those with a deficiency or high stress levels—rather than for the general population.
5 ways to get more magnesium into your diet
One way to avoid being deficient in magnesium is by eating foods rich in it. These foods can give you a natural and safe way to meet your daily requirements, without the risk of overdoing it. Plus, they’re also packed with other nutrients that support overall health.
Here are five simple and practical ways you can add more magnesium into your meals and snacks:
1. Load up on leafy greens
Leafy green vegetables like spinach, swiss chard, kale, and collard greens are magnesium powerhouses. If you have just one cup of cooked spinach, this contains about 157 mg of magnesium.
Consider tossing a handful of spinach or kale into your morning smoothie. You could also use swiss chard or collard greens as a wrap for sandwiches or sauté greens with garlic and olive oil for a yummy side dish.
Try this: If you’re not a fan of spinach or greens, you could add magnesium into your diet by drinking mineral or sparkling waters that contain magnesium.
💙 Listen to Tamara Levitt’s Mindful Eating Series to help get you in the right mindset for healthy eating.
2. Snack on nuts and seeds
Nuts and seeds like almonds, cashews, and pumpkin seeds are really high in magnesium. A one ounce serving of pumpkin seeds provides 168 mg of magnesium.
To incorporate more nuts and seeds into your snacks, consider sprinkling chia seeds, flaxseeds, or hemp seeds onto your oatmeal or yogurt. You can also use nut butters as a spread on whole-grain toast or as a dip for apple slices.
Try this: If you’re always on the go, consider keeping a small bag of mixed nuts and seeds in your bag or car. These are easier snacks to eat while travelling and can also give you a much-need energy boost. (And if you’re constantly moving and find it hard to take breaks, here are 20 mindful ways to do that.)
💙 To help get a little movement in after you eat, watch After Lunch with Mel Mah.
3. Embrace whole grains
Some other excellent sources of magnesium are whole grains like quinoa, brown rice, oats, and whole-grain bread. Just one cup of cooked quinoa gives you about 118 mg of magnesium.
Try to choose whole-grain versions of pasta, bread, and cereals. You could make quinoa or brown rice the base for bowls you have with roasted veggies and lean proteins. Also, a hearty bowl of steel-cut oats topped with fresh fruit and nuts can be another great way to squeeze in some whole grains into your day.
Try this: If you start to get bored of your whole grains, add magnesium-rich spices to some of your dishes like coriander, basil, or dill. This can liven up your diet and give you an extra sprinkle of nutrients.
4. Add legumes to your meals
Beans, lentils, and chickpeas not only can make a versatile addition to your meals, but they’re also rich in magnesium. Case in point: One cup of cooked black beans contains about 120 mg of magnesium.
To get more magnesium into your day, consider using lentils as a filling for wraps or adding black beans to salads and soups. If you love dips, maybe blend chickpeas into a creamy homemade hummus.
Try this: Soaking or sprouting beans in water for a few days can boost their magnesium levels.
5. Treat yourself to dark chocolate
If you love dark chocolate, start doing a little happy dance: It’s also a good source of magnesium. A one ounce piece of dark chocolate (70–85% cacao) can contain up to 64 mg of magnesium. It can also contain antioxidants and mood-boosting compounds.
To add more dark chocolate into your diet, consider pairing a square with a handful of nuts for a tasty dessert. You could also try using cacao powder to make a magnesium-packed hot chocolate. (If you tend to indulge in a little too much chocolate when you’re in your feelings, here are five strategies that can help.)
Try this: If you love fruit, consider melting dark chocolate and drizzling it over fresh fruit like strawberries or bananas. (Hold please, we’re testing this out ourselves.)
Magnesium sleep FAQs
Can magnesium supplements help with insomnia?
The short answer is no, but maybe. Magnesium supplements may be able to help to improve your sleep if you’re dealing with a magnesium deficiency. (If you’re experiencing insomnia or other chronic sleep issues, try these 10 strategies that can help you manage.)
If you have insomnia, reach out to a doctor to see if they can help you address your underlying causes. They might be able to better help you treat your insomnia or determine if supplements are a good addition to your sleep regimen.
What is excessive magnesium intake?
When you consume more magnesium than your body can process—typically through supplements rather than food—this is considered excessive magnesium intake.
The National Institutes of Health says the tolerable upper intake level (UL) for supplemental magnesium per day for adults is about 200-400 mg. To make sure you don’t overdo it, talk to your doctor before taking magnesium supplements.
If you’re currently worried you exceeded the limit, here are possible symptoms to look out for:
Diarrhea
Nausea
Abdominal cramping
Low blood pressure
Irregular heartbeat
Are there any side effects of mixing magnesium with other supplements?
Mixing magnesium with other supplements and medications can cause unwanted side effects.
Taking high doses of calcium and magnesium together can possibly cause them to compete for absorption, and reduce their effectiveness. Similarly, if you mix magnesium with medications like diuretics, you can seriously throw off your electrolyte balance.
To avoid some of these potential side effects, talk to your doctor, especially if you're on medications or taking other supplements. They can help advise you on the best way to add magnesium into your routine.
Can low levels of magnesium cause other health problems?
Having low levels of magnesium can contribute to various health issues beyond just poor sleep. Magnesium helps you to maintain healthy nerve and muscle function, regulates your blood sugar levels, and supports your bone health. If you have low magnesium levels, you can possibly experience:
Muscle cramps
Irritability
Difficulty concentrating
Over time, chronic magnesium deficiency can also increase your risks for more serious conditions like:
Heart disease
Type 2 diabetes
Osteoporosis
To help prevent these complications, consider adding magnesium-rich foods or supplements into your diet. If you do experience any of these symptoms, reach out to your doctor to set up an appointment.
Calm your mind. Change your life.
Mental health is hard. Getting support doesn't have to be. The Calm app puts the tools to feel better in your back pocket, with personalized content to manage stress and anxiety, get better sleep, and feel more present in your life.