Magnesium in Pregnancy: Benefits, Foods, Supplements, and How Much You Need
Magnesium is an essential mineral during pregnancy that supports everything from muscle and nerve function to energy production, blood sugar regulation, and your baby’s growth and development.
Your magnesium needs increase during pregnancy.
But does that mean you need a magnesium supplement? And what about magnesium for sleep, constipation, leg cramps, or morning sickness?
Here’s what you need to know about getting enough magnesium during pregnancy, including how much you need, the best food sources, the different types of magnesium supplements, and what the research actually says.
Why Magnesium Matters During Pregnancy
Magnesium is an essential mineral involved in hundreds of enzymatic reactions throughout the body. It helps your nerves communicate, your muscles contract and relax, and your heart maintain a regular rhythm.
Magnesium also plays a role in:
- Energy production
- Protein synthesis
- Blood sugar regulation
- Normal blood pressure
- DNA and RNA synthesis
- Electrolyte balance
- Bone health
During pregnancy, magnesium supports both your changing body and your baby’s growth. It contributes to fetal bone and tooth development and works alongside nutrients like calcium and vitamin D to support healthy bones.
Because of these roles, magnesium has also been studied in relation to pregnancy concerns including gestational diabetes, preeclampsia, preterm birth, nausea, leg cramps, headaches, and sleep.
That doesn’t necessarily mean taking more magnesium will prevent or treat all of these concerns. Your overall magnesium intake, nutritional status, health history, and the reason you’re considering supplementation all matter.
How Much Magnesium Do You Need During Pregnancy?
Magnesium needs increase during pregnancy. The recommended dietary allowance, or RDA, depends on your age:
| Age | Recommended amount during pregnancy |
|---|---|
| 14–18 years | 400 mg/day |
| 19–30 years | 350 mg/day |
| 31–50 years | 360 mg/day |
These recommendations include magnesium from food, beverages, supplements, and medications.
For comparison, the RDA for nonpregnant women is 310 mg per day for ages 19–30 and 320 mg per day for ages 31–50.
What About the Upper Limit for Magnesium?
The tolerable upper intake level for magnesium from supplements and medications is 350 mg per day for adults.
This does not include magnesium naturally found in food.
So you don’t need to worry about going over the upper limit because you ate an extra serving of pumpkin seeds, spinach, or black beans.
The 350 mg upper limit also isn’t a recommended supplement dose. It’s a safety threshold intended primarily to reduce side effects associated with higher supplemental intakes.
Check your prenatal vitamin before adding another magnesium supplement, too. Some prenatals contain magnesium, although many don’t provide the entire pregnancy RDA.
Magnesium-Rich Foods to Eat During Pregnancy
Food is a great place to start because magnesium-rich foods usually provide other pregnancy-supportive nutrients at the same time, including fiber, protein, fats, vitamins, and minerals.
Some of our favorite magnesium-rich foods include:
- Seeds and nuts: pumpkin seeds, chia seeds, almonds, cashews, peanuts, and peanut butter
- Beans and legumes: black beans, kidney beans, lentils, chickpeas, soybeans, and edamame
- Vegetables: cooked spinach, Swiss chard, avocado, and potatoes with the skin
- Whole grains: oatmeal, brown rice, whole-wheat bread, and other minimally processed grains
- Other foods: yogurt, milk, some fish, avocado, and dark chocolate
You don’t need to completely overhaul your diet to get more magnesium.
Try adding pumpkin seeds or peanut butter to oatmeal, using black beans or lentils in tacos or bowls, adding avocado to lunch, serving brown rice with dinner, or mixing cooked spinach into eggs or pasta.
A simple way to increase your intake is to include a magnesium-rich food at several meals throughout the day.
Can You Take Magnesium Supplements While Pregnant?
Magnesium supplements can be used during pregnancy when there’s a clear reason, and the dose is appropriate.
But routine magnesium supplementation isn’t necessarily needed for everyone.
A magnesium supplement may be worth discussing with your healthcare provider or dietitian if:
- Your dietary magnesium intake is consistently low
- Your prenatal contains little or no magnesium
- You have a gastrointestinal condition that affects nutrient absorption
- You have persistent vomiting or another reason your intake may be limited
- You’re considering magnesium to address a specific symptom
Magnesium supplementation has also been researched for several pregnancy complications, including preeclampsia and gestational diabetes.
However, the research isn’t straightforward.
Magnesium and Preeclampsia
Magnesium supports normal blood pressure regulation, but research on supplementation during pregnancy has produced mixed results.
One randomized placebo-controlled trial found that 300 mg of magnesium supplementation beginning at 25 weeks was associated with lower diastolic blood pressure later in pregnancy.
Another randomized trial found that 300 mg per day did not significantly reduce the incidence of preeclampsia.
Because of these mixed findings, oral magnesium supplements aren’t routinely recommended as a stand-alone strategy for preventing preeclampsia.
In hospitals, magnesium sulfate may be used under medical supervision to prevent or treat seizures linked to severe preeclampsia and eclampsia.
It’s different from over-the-counter magnesium supplements, which should not replace blood pressure monitoring or medical treatment.
Magnesium and Gestational Diabetes
Magnesium plays a role in glucose metabolism and insulin function.
A 2022 meta-analysis found that magnesium supplementation improved fasting glucose and some insulin-related markers in pregnant women with gestational diabetes, but the included studies were small.
Magnesium can be one part of a blood-sugar-supportive pregnancy diet, but it does not replace standard gestational diabetes care.
Magnesium and Morning Sickness
Magnesium sometimes comes up as a potential support for pregnancy nausea and hyperemesis gravidarum.
Low magnesium status and nausea or vomiting may occur together, particularly when persistent vomiting makes it difficult to eat enough food and maintain adequate nutrient intake.
However, strong evidence doesn’t show that magnesium supplementation alone reliably treats morning sickness or hyperemesis gravidarum.
Vitamin B6 has stronger evidence for pregnancy nausea and is commonly used as a first-line option. You can learn more in our Vitamin B6 for Morning Sickness guide.
If you’re experiencing persistent or severe nausea and vomiting, talk with your healthcare provider rather than assuming magnesium deficiency is the cause.
Which Type of Magnesium Is Best During Pregnancy?
Different forms of magnesium vary in absorption and how they affect digestion.
Magnesium glycinate is generally well tolerated and less likely to cause loose stools, while magnesium citrate has more of a laxative effect and may help if constipation is also a concern.
Other forms, including magnesium oxide, chloride, hydroxide, and malate, are also available, but the best option depends on why you’re taking it.
When comparing supplements, look at the amount of elemental magnesium on the label. That’s what counts toward your total supplemental intake.
Can You Get Too Much Magnesium?
Getting too much magnesium from food isn’t typically a concern for healthy people.
Supplemental magnesium is different.
Taking too much can cause:
- Diarrhea
- Nausea
- Abdominal cramping
Extremely high doses of magnesium-containing laxatives or medications can lead to magnesium toxicity.
The risk is higher for people with impaired kidney function because the kidneys remove excess magnesium from the body.
Magnesium can also interfere with the absorption of certain medications, including some antibiotics, so supplement timing may matter.
Talk with your healthcare provider before adding supplemental magnesium if you have kidney problems, persistent diarrhea or vomiting, a gastrointestinal condition, or regularly take medications.
Do You Need a Magnesium Supplement During Pregnancy?
Not necessarily.
Magnesium is incredibly important during pregnancy, but needing more of a nutrient doesn’t automatically mean you need a separate supplement.
Start by looking at:
- How much magnesium you regularly get from food
- How much is already in your prenatal
- Whether you have conditions that affect magnesium absorption
- Whether you’re taking medications that affect magnesium status
- Why you’re considering supplementation in the first place
If your diet is low in magnesium-rich foods or your prenatal contains very little, adding more magnesium may make sense.
But if you’re specifically using magnesium for constipation, headaches, nausea, sleep, leg cramps, blood sugar, or blood pressure concerns, talk with your provider or prenatal dietitian so you can address the underlying issue rather than simply adding another supplement.
Pregnancy Nutrition Shouldn’t Take This Much Work
One minute you’re checking whether a food is safe. The next you’re reading your prenatal label, looking up a nutrient, or trying to figure out what to make for dinner. It adds up fast.
The TPNL app gives you one place to sort through pregnancy nutrition without bouncing between Google, ingredient lists, and random advice. Inside the app, you can check pregnancy-safe foods and ingredients, see which nutrients matter, find foods to prioritize, and get meal ideas based on where you are in pregnancy.
Less searching. More knowledge about what to eat and what to watch for.
When to Talk With Your Healthcare Provider
Talk with your healthcare provider before starting a magnesium supplement if you have kidney disease, gastrointestinal conditions, persistent vomiting or diarrhea, or take medications such as antibiotics, diuretics, or thyroid medication.
You should also seek medical care for symptoms such as:
- Severe headache
- Vision changes
- Sudden swelling
- Chest pain
- Shortness of breath
- Very high blood pressure
- Fainting
- An irregular heartbeat
- Reduced fetal movement
These symptoms require proper medical assessment and shouldn’t be attributed to low magnesium alone.
The Bottom Line
Magnesium is an important pregnancy nutrient that supports your muscles, nerves, energy production, blood sugar regulation, and your baby’s growth and bone development.
Most pregnant adults need 350–360 mg of magnesium per day, and foods like nuts, seeds, beans, whole grains, avocado, potatoes, and cooked leafy greens can help you reach that amount.
A magnesium supplement can be helpful in some situations, but it isn’t automatically necessary just because you’re pregnant.
Before adding one, check how much magnesium is already in your prenatal and consider why you’re taking it. Your healthcare provider or prenatal dietitian can help you determine whether you need additional magnesium and which form and dose make the most sense.
Frequently Asked Questions
What does magnesium do during pregnancy?
Magnesium supports muscle and nerve function, energy production, blood sugar and blood pressure regulation, DNA and protein synthesis, and fetal bone development.
How much magnesium do I need during pregnancy?
Pregnant people ages 19–30 need 350 mg of magnesium per day, while those ages 31–50 need 360 mg per day. Pregnant teens ages 14–18 need 400 mg per day.
Can I get enough magnesium from food during pregnancy?
Yes, you can meet your magnesium needs through food. Nuts, seeds, beans, whole grains, avocado, potatoes, and cooked leafy greens are all good sources.
Is it safe to take magnesium supplements while pregnant?
Magnesium supplements can be used during pregnancy when appropriate, but the right amount depends on your diet, prenatal vitamin, medications, health history, and reason for taking it. Talk with your healthcare provider before adding a separate supplement.
Can magnesium help pregnancy constipation?
Certain forms—particularly magnesium citrate and magnesium hydroxide—can loosen stools and are sometimes used for constipation. Talk with your healthcare provider before using magnesium specifically to treat persistent constipation during pregnancy.
Can magnesium help with leg cramps or sleep during pregnancy?
Magnesium may be helpful when inadequate magnesium intake or deficiency is contributing to symptoms, but research supporting routine supplementation for pregnancy-related leg cramps or sleep concerns is inconsistent.
Can magnesium help morning sickness?
Strong evidence doesn’t show that magnesium supplements reliably treat morning sickness or hyperemesis gravidarum. Vitamin B6 has stronger evidence for pregnancy nausea.
Ryann Kipping
Licensed Dietitian & Founder of The Prenatal Nutrition Library
Prenatal dietitian with a Master's in Public Health and author of The Feel-Good Pregnancy Cookbook. Founder of The Prenatal Nutrition Library App.
Make pregnancy nutrition simple.
Get custom meal plans, 600+ dietitian-approved recipes, and our "Can I eat…?" search—plus, trimester-by-trimester nutrition priorities and more.




