Magnesium is going viral as a natural sleep aid. But is it safe?

Magnesium supplements are becoming increasingly popular on social media. On TikTok, many people swear by taking magnesium daily to aid with sleep, anxiety and even constipation — which may leave you wondering about the best time to take magnesium.

More than half of all adults in the United States take dietary supplements regularly, according to the U.S. Centers for Disease Control and Prevention. However, research has shown that the vitamins many people take every day may not be doing much to make us healthier at all.

“Magnesium is one of the most abundant minerals in your body and it’s involved in more than 300 chemical reactions that help your body function properly,” Perri Halperin, dietitian and clinical nutrition coordinator at Mount Sinai Health System, tells TODAY.com.

Here's what know about magnesium supplements, who should be take them, and if they're safe to take every day.

Magnesium benefits

Magnesium is an essential nutrient our bodies need to function. The mineral is found naturally in many foods, added to certain food products, sold as a dietary supplement, and present in medications such as antacids and laxatives, according to the National Institutes of Health's Office of Dietary Supplements.

"Magnesium plays a role in managing blood sugar and pressure, ensuring nerves and muscles work properly and strengthening bones," says Halperin.

Magnesium also helps with regulating heart rhythm, protein synthesis and energy production, Amber Sommer, a registered dietitian nutritionist at the Cleveland Clinic, tells TODAY.com. "It's very, very important, and we need quite a bit of it."

Studies have shown that getting enough magnesium is associated with reduced risk of high blood pressure and Type 2 diabetes, according to the NIH. It may also lower the risk of osteoporosis and reduce the frequency of migraines, but more research is needed.

Magnesium dosage

The daily intake or recommended dietary allowance for magnesium varies by age and sex. For adults, it’s 400–420 milligrams for males and 310–320 milligrams for females, per the NIH.

The upper limit for magnesium from supplements is 350 milligrams per day, says Halperin. The upper limit for supplements is lower than the recommended daily amount because that amount includes magnesium from food and other sources, per the NIH.

Most people can get the recommended amount of magnesium every day by eating a well-balanced diet full of a variety of foods, including plants, according to the experts.

While getting too much magnesium from food does not pose a risk for healthy people, per the NIH, consuming high doses of magnesium from supplements can cause problems.

“High-dose supplements can lead to diarrhea, nausea and muscle weakness,” says Halperin. Extremely high doses of magnesium can lead to an irregular heart beat or cardiac arrest, per the NIH.

Magnesium foods

According to the experts, magnesium is found in lots of foods, such as:

  • Legumes

  • Dark green leafy vegetables

  • Nuts and seeds, especially pumpkin seeds

  • Whole grains

  • Fish

  • Poultry

  • Beef

  • Milk

  • Yogurt

  • Fortified cereals

"However, it’s important to know that the body only absorbs around 30–40% of the dietary magnesium a person consumes, so this may make it challenging for some people to get enough of this nutrient from their diet," says Halperin.

Additionally, many people in the United States do not eat a healthy diet, and often opt for more processed foods that are lower in nutritional value, according to the CDC.

“If somebody has dietary restrictions, (has to) avoid certain food groups, or doesn’t have a well-balanced diet ... they may not be getting enough magnesium," says Sommer.

Symptoms of magnesium deficiency

Not getting enough magnesium over a long period of time may lead to a deficiency, but there's only one way to know: "A deficiency needs to be detected via a blood test," says Halperin.

Especially in the early stages, many people with a magnesium deficiency have no symptoms or only mild symptoms, so "you are probably unaware" if you have a deficiency, says Halperin.

Over time, a magnesium deficiency can worsen and produce more noticeable symptoms, according to the experts. These include:

  • Nausea

  • Fatigue

  • Numbness

  • Muscle cramps

  • Constipation

  • Brain fog

  • In severe cases, seizures and heart problems, such as abnormal heart rhythm

Overall, magnesium deficiencies due to low dietary intake are uncommon in healthy people, per the NIH. However, certain groups are higher risk, such as those with gastrointestinal disease like Crohn's or celiac disease, people with Type 2 diabetes, people with alcoholism and older adults.

Is it OK to take magnesium every day?

Yes, it is generally safe for most people to take magnesium supplements daily as long as you stay within the recommended daily intake and are doing so at the recommendation of a health care provider, the experts say.

You should also talk to your doctor about which type of magnesium supplement is best for you. It's sold in pill, powder and liquid forms.

There are also different types of magnesium, which vary in terms of how they’re absorbed in the body, possible side effects and the intended use. For example, magnesium aspartate, magnesium citrate, magnesium lactate and magnesium chloride are more easily absorbed, research shows. Magnesium glycinate is another popular form, often marketed to support relaxation.

"You don’t want people to be taking the wrong type or taking too much, and there are so many different supplements out there, so it’s hard to know which one to take,” Sommer explains.

Always talk to your doctor before trying a magnesium supplement, the experts emphasize.

“The bottom line is nutritious foods are the best way to get vitamins and minerals, (and) supplements can be used as a complement to help correct any potential deficiencies,” says Halperin.

Magnesium for sleep

There is some research suggesting that magnesium may be beneficial for sleep, according to the experts.

A 2023 systematic review of existing studies on magnesium and sleep health found that there may be an association between magnesium levels and sleep quality, but more research is needed, the study authors wrote.

"It may help regulate neurotransmitters that are directly related to sleep, affect levels of melatonin and help relax muscles," says Halperin.

Magnesium glycinate is the form commonly used as a sleep aid, Halperin adds, and the recommendation is taking about 200 milligrams of magnesium glycinate 30 minutes before bedtime.

Magnesium for anxiety

"Additionally, research has shown that supplementation with magnesium glycinate may contribute to improvement in cases of depression, anxiety and memory loss, (but) the mechanism of action is still unknown," says Halperin.

Studies have shown that there is suggestive but inconclusive evidence that magnesium supplements have a beneficial effect for mild anxiety, according to a 2017 literature review published in the journal Nutrients.

In any case, magnesium supplements are not a substitute for medical care, experts warn.

What is the best time of day to take magnesium?

If you're taking magnesium for sleep, take it at night before bedtime, says Halperin. The recommendation for magnesium glycinate for sleep is 200 milligrams 30 minutes before going to sleep.

Otherwise, magnesium supplements can be taken at any time of the day, with or without food, says Halperin. Just keep in mind what other supplements and medications you're taking to avoid any possible interactions.

For example, calcium can interfere with absorption of magnesium, iron and zinc, so it’s best to take any calcium supplements at a different meal from your magnesium supplement, says Halperin.

Magnesium interactions

Magnesium supplements can interfere with certain medications, including those for thyroid disorders or HIV, and certain antibiotics, says Halperin. And in people with chronic kidney disease, magnesium supplements may result in excess accumulation of magnesium in the blood, which could become toxic, says Sommer.

"It’s crucial that those with chronic conditions talk to a medical professional before taking magnesium," Halperin adds.

It’s also important to remember that dietary supplements are not approved by the U.S. Food and Drug Administration, says Sommer.

This article was originally published on TODAY.com