ConditionHormones & metabolism
Magnesium Deficiency
Magnesium deficiency means your body has too little magnesium, a mineral needed for muscles, nerves, heart rhythm, bones and blood sugar control. Mild shortfalls from diet are common and usually cause no clear symptoms. True deficiency, called hypomagnesemia when the blood level is low, causes muscle cramps, twitching, tremor, weakness and, when severe, seizures and dangerous heart rhythms. It is most often caused by medicines, alcohol, diabetes or gut problems, and is treated with magnesium-rich foods, supplements or IV magnesium.
Also called: Hypomagnesemia, low magnesium, magnesium insufficiency
At a glance
- What it is
- A shortage of magnesium in the body, shown on blood tests as hypomagnesemia (below about 1.7 to 1.8 mg/dL, or 0.7 mmol/L).
- Common causes
- Long-term acid-reducing medicines (PPIs), diuretics, alcohol, poorly controlled diabetes, diarrhea and gut malabsorption.
- Symptoms
- Cramps, twitching, tremor, fatigue, palpitations; seizures and arrhythmias when severe.
- Often comes with
- Low potassium and low calcium that will not correct until magnesium is replaced.
- Treatment
- Magnesium-rich diet, oral supplements, IV magnesium for severe cases, and fixing the cause.
When to get help
Call 911 or go to the ER
- A seizure, or a racing, fluttering or irregular heartbeat with fainting or chest pain
- Severe muscle spasms, including spasm of the throat (laryngospasm) causing noisy breathing
- Confusion or extreme weakness in someone with heavy drinking, severe diarrhea or known low magnesium
See a doctor within a day or two
- Persistent twitching, tremor or tingling around the mouth and fingers
- New palpitations while taking diuretics, PPIs or other medicines that lower magnesium
- Muscle weakness with low potassium or calcium results that are not responding to treatment
Book a routine appointment
- Frequent leg cramps or eyelid twitching with long-term PPI or diuretic use
- Chronic diarrhea, celiac or Crohn's disease, or bariatric surgery with fatigue or cramps
- Considering daily magnesium supplements when you have kidney disease
Usually safe to manage at home
- Occasional muscle cramps or eyelid twitches in a healthy person, with more magnesium-rich foods
What magnesium does
Your body holds about 25 grams of magnesium, mostly in bones and inside cells. Less than 1% is in the blood. Magnesium is involved in more than 300 enzyme reactions, including:
- energy production in every cell
- muscle relaxation after contraction
- nerve signaling
- a steady heart rhythm
- insulin action and blood sugar control
- keeping potassium and calcium in balance
- bone strength
Symptoms of magnesium deficiency
Mild deficiency rarely causes clear symptoms. Signs become more obvious as levels fall, especially below about 1.2 mg/dL (0.5 mmol/L).
Early or mild
- loss of appetite, nausea
- tiredness and weakness
- muscle cramps, especially in the legs at night
- eyelid or muscle twitching
Moderate to severe
- tremor and shaking
- numbness or tingling, particularly around the mouth, hands and feet
- muscle spasms; tapping in front of the ear may make the face twitch (Chvostek sign)
- irritability, anxiety, confusion, depression
- palpitations and an irregular heartbeat, including a dangerous rhythm called torsades de pointes
- seizures
Many of these overlap with low potassium and low calcium, which often occur at the same time.
Causes and risk factors
| Category | Examples |
|---|---|
| Medicines | Proton pump inhibitors (omeprazole, pantoprazole) taken for more than a year; loop and thiazide diuretics; some antibiotics (aminoglycosides) and antifungals (amphotericin B); cisplatin; calcineurin inhibitors after transplant; EGFR-blocking cancer drugs |
| Gut losses | Chronic diarrhea, celiac disease, Crohn's disease, short bowel syndrome, bariatric surgery, laxative overuse, prolonged vomiting |
| Kidney losses | Poorly controlled diabetes (glucose in the urine), recovery from kidney injury, genetic conditions such as Gitelman syndrome |
| Alcohol | Poor diet, increased urine losses and diarrhea; very common in alcohol use disorder |
| Low intake | Diets low in whole grains, nuts, beans and greens; older adults; malnutrition |
| Other | Acute pancreatitis, refeeding after starvation, "hungry bone syndrome" after thyroid or parathyroid surgery, pregnancy complications |
People with type 2 diabetes commonly have low magnesium, and low levels may worsen insulin resistance.
Why low magnesium causes low potassium and calcium
Magnesium is needed for the kidneys to hold on to potassium and for the parathyroid glands to release the hormone that maintains calcium. So when magnesium is low, hypokalemia and hypocalcemia often follow, and they will not correct with potassium or calcium alone. Replacing magnesium first is a standard step in treating them.
How magnesium deficiency is diagnosed
- Serum magnesium: the usual blood test. Normal is roughly 1.7 to 2.2 mg/dL (0.70 to 0.95 mmol/L), depending on the laboratory. Because so little magnesium is in the blood, a normal result does not rule out a body-wide shortfall.
- Other electrolytes: potassium, calcium, phosphate and kidney function.
- ECG: to look for rhythm changes such as a prolonged QT interval.
- Urine magnesium: helps tell whether the kidneys or the gut are losing it.
Home tests and hair analysis are not reliable for diagnosing magnesium deficiency.
Treatment
Severe or symptomatic deficiency
IV magnesium sulfate is given in the hospital for seizures, arrhythmias, or very low levels, with heart monitoring.
Mild to moderate deficiency
- Oral magnesium supplements, usually in divided doses to reduce diarrhea. Your clinician will advise the amount.
- Address the cause: stop or switch a PPI if possible, adjust diuretics (potassium-sparing diuretics such as amiloride also reduce magnesium loss), control blood sugar, treat diarrhea, cut down on alcohol.
Choosing a supplement
| Form | Notes |
|---|---|
| Magnesium citrate, glycinate, lactate, chloride | Better absorbed; glycinate is gentler on the gut |
| Magnesium oxide | High magnesium content but poorly absorbed; more likely to cause diarrhea |
| Magnesium hydroxide | Used mainly as a laxative or antacid |
Follow the label dose. The upper limit for supplemental magnesium in adults is 350 mg a day unless a doctor advises more. Diarrhea is the main side effect. People with kidney disease should not take supplements without medical advice, because magnesium can build up to toxic levels. Magnesium supplements can reduce absorption of some antibiotics (tetracyclines, quinolones) and osteoporosis drugs (bisphosphonates), so separate the doses by a few hours.
Foods high in magnesium
The recommended daily intake is about 400 to 420 mg for adult men and 310 to 320 mg for adult women (350 to 360 mg in pregnancy).
| Food | Approximate magnesium |
|---|---|
| Pumpkin seeds, 1 oz (28 g) | 150 mg |
| Chia seeds, 1 oz | 110 mg |
| Almonds, 1 oz | 80 mg |
| Spinach, boiled, ½ cup | 78 mg |
| Cashews, 1 oz | 74 mg |
| Black beans, cooked, ½ cup | 60 mg |
| Edamame, ½ cup | 50 mg |
| Peanut butter, 2 tablespoons | 49 mg |
| Brown rice, cooked, ½ cup | 42 mg |
| Avocado, 1 cup cubed | 44 mg |
| Dark chocolate (70% to 85%), 1 oz | about 65 mg |
Whole grains, legumes, nuts, seeds and leafy greens are the richest sources. Refining grains removes most of their magnesium.
Frequently asked questions
What are the first signs of magnesium deficiency?
Early signs are often vague: loss of appetite, nausea, tiredness, weakness, muscle cramps and twitching such as eyelid flickers. As levels fall further, tingling, tremor, mood changes and palpitations appear. Many people with mild deficiency have no symptoms at all.
What causes low magnesium?
The most common causes are long-term proton pump inhibitor use, diuretics, heavy alcohol use, poorly controlled diabetes, chronic diarrhea and gut conditions that reduce absorption, such as celiac or Crohn's disease. A low-magnesium diet contributes but rarely causes severe deficiency on its own.
How long does it take to correct a magnesium deficiency?
IV magnesium raises blood levels within hours. With oral supplements and diet, blood levels usually improve within days to a couple of weeks, but refilling body stores can take several weeks. If the cause, such as a medicine, continues, levels may fall again.
Can magnesium deficiency cause anxiety or poor sleep?
Low magnesium can cause irritability, anxiety and restlessness, and severe deficiency can cause confusion. Evidence that supplements improve anxiety or sleep in people with normal levels is limited and mixed. Persistent anxiety or insomnia has many causes and deserves a proper assessment.
Can you take too much magnesium?
From food, no, because healthy kidneys remove the excess. From supplements, high doses commonly cause diarrhea and cramps. Very high doses, or normal doses in people with kidney failure, can cause dangerous magnesium toxicity with weakness, low blood pressure and slowed breathing.
Sources
This guide was written from current patient and clinical guidance, including:
- NIH Office of Dietary Supplements: Magnesium Fact Sheet for Health Professionals
- MedlinePlus: Magnesium in diet; Low blood magnesium
- US FDA: Drug Safety Communication, low magnesium levels with long-term use of proton pump inhibitors
- National Academies: Dietary Reference Intakes for Calcium, Phosphorus, Magnesium, Vitamin D, and Fluoride
- Kidney Disease: Improving Global Outcomes (KDIGO): Controversies conference on potassium and magnesium