In this article
The idea that cramps (muscle cramps) are caused by a mineral deficiency is deeply rooted, and has some basis: magnesium, calcium and potassium are essential for nerve and muscle function, and marked changes in the blood levels of these minerals can indeed cause cramps.
However, in most people with cramps, blood mineral levels are within the reference range, and supplements have shown modest or no benefit in studies. This article explains the role of each mineral, what the tests measure, when levels change and what the evidence says about supplements. The ranges given are approximate and vary between laboratories: always use those on your own report. The doctor who ordered the tests is responsible for interpreting them.
How minerals control muscles
Muscle contraction depends on electrical signals travelling along the nerves and across the muscle fibre membrane. These signals are produced by ions (sodium, potassium and calcium) passing through channels in the membrane. Calcium is the final trigger for contraction within the fibre, while magnesium helps regulate nerve excitability and muscle relaxation.
When blood concentrations of these minerals stray far from normal, the nerves can become more excitable and fire on their own, encouraging cramps, tingling and involuntary contractions. This mechanism lends credibility to the mineral theory. The practical question is how often these changes are found in people with ordinary cramps. The answer is: rarely.
| Mineral | Role in muscles and nerves | Effect of low levels |
|---|---|---|
| Magnesium | Stabilises nerves, helps muscles relax | Excitability, cramps, tremor, abnormal heart rhythms |
| Calcium | Triggers contraction | Tingling, spasms (tetany), cramps |
| Potassium | Maintains the electrical potential of cells | Weakness, cramps, abnormal heart rhythms |
| Sodium | Transmission of nerve impulses | Cramps, confusion and nausea in marked cases |
Magnesium: the most sought-after supplement
Magnesium is the supplement most commonly used for cramps. Magnesium deficiency can occur with prolonged diarrhoea, excessive alcohol consumption, poorly controlled diabetes, some diuretics and long-term use of proton pump inhibitors (medicines for stomach acid). In these situations, low magnesium may be accompanied by cramps, tremors and, in severe cases, abnormal heart rhythms.
In other circumstances, research does not support magnesium as a treatment for ordinary cramps. An updated 2020 Cochrane systematic review found that it probably provides no clinically meaningful benefit for older people with ordinary cramps. Research on cramps during pregnancy has produced conflicting findings, so no clear conclusion can be drawn. No appropriate trials had examined exercise-associated cramps.
What the evidence says about magnesium
It is important to be clear about what the review does and does not show. It shows that, in the available trials, the difference between magnesium and placebo in the frequency and severity of cramps in older adults was very small. It does not rule out a benefit from correcting magnesium in people with a genuine deficiency, nor does it cover specific situations such as kidney disease or cirrhosis.
The most common side effects of oral magnesium are digestive problems, particularly diarrhoea. In people with kidney disease, magnesium can build up and become dangerous. Supplements should therefore be taken on medical advice. As a general guide, the dose should be the one recommended by the doctor or pharmacist for the individual situation.
| Study group | Overall conclusion of the Cochrane review (2020) |
|---|---|
| Older adults with ordinary cramps | Magnesium probably has no clinically meaningful benefit |
| Pregnant women | Conflicting results, inconclusive evidence |
| Exercise-associated cramps | No suitable trials |
| People with a confirmed deficiency | Outside the scope of the review; correction is decided by the doctor |
Calcium: important, but rarely the cause
Blood calcium is very precisely regulated by parathyroid hormone and vitamin D. When calcium falls significantly (hypocalcaemia), it can cause tingling around the mouth and in the hands, spasms of the hands and feet, and cramps. This can happen after thyroid or parathyroid surgery, with severe vitamin D deficiency, kidney disease and some medicines.
In ordinary cramps, calcium is almost always normal. Calcium supplements have been used for cramps in pregnancy, but evidence of benefit is weak. Too much calcium also carries risks, including kidney stones and interactions with medicines, so it should be taken only on medical advice.
How to read calcium results
Total blood calcium depends on albumin, the protein that carries some of it. If albumin is low, total calcium may appear low even though the 'active' calcium is unchanged. The laboratory or doctor may therefore calculate corrected calcium or request an ionised calcium test.
The ranges below are only approximate for adults; each laboratory provides its own, which may use different units and limits.
| Test | Approximate range in adults | Note |
|---|---|---|
| Total calcium | Around 2.2 to 2.6 mmol/L (8.5 to 10.5 mg/dL) | Interpret alongside albumin |
| Ionised calcium | Around 1.1 to 1.3 mmol/L | Requires careful sample collection |
| Magnesium | About 0.7 to 1.0 mmol/L (1.7 to 2.4 mg/dL) | The blood level may not reflect the body's stores |
| Potassium | About 3.5 to 5.0 mmol/L | Sensitive to collection errors |
| Sodium | About 135 to 145 mmol/L | Small changes are common |
Potassium: the mineral that needs most attention
Low potassium (hypokalaemia) can cause muscle weakness, cramps, constipation and abnormal heart rhythms. The most common causes are diuretics, vomiting, diarrhoea and laxative misuse. High potassium (hyperkalaemia) usually causes few symptoms, but can lead to serious abnormal heart rhythms. It occurs mainly in people with kidney disease and with some medicines for blood pressure and the heart.
Very abnormal potassium levels require medical advice that day and sometimes an urgent assessment, particularly if there are palpitations, marked weakness or fainting. Potassium supplements should be taken only on prescription, as too much can be dangerous, especially for people with kidney disease or those taking certain medicines.
Why a result can be abnormal when there is no illness
Potassium is very sensitive to the conditions in which the sample is taken. Leaving a tourniquet on too long, repeatedly clenching the hand, delays in processing or the breakdown of red blood cells in the sample (haemolysis) can make potassium appear falsely high. An unexpectedly high potassium result is therefore often repeated before any conclusions are drawn.
Blood magnesium tests also have limitations: most magnesium is inside cells and bones, so a normal blood level does not completely rule out a deficiency. These nuances are part of the reason why the doctor should interpret the result alongside symptoms and the patient's medical history.
| Factor | Possible effect on the result |
|---|---|
| Sample haemolysis | Falsely high potassium and magnesium |
| Prolonged tourniquet use, forcefully clenched hand | Falsely high potassium |
| Low albumin | Falsely low total calcium |
| Diuretics | Low potassium and magnesium |
| Long-term proton pump inhibitor use | Low magnesium |
When laboratory tests are appropriate
A 2012 review of night cramps states that routine electrolyte tests are not necessary for typical cramps. Tests are warranted when a cause is suspected: the use of diuretics, prolonged vomiting or diarrhoea, kidney disease, excessive alcohol consumption, recent thyroid surgery, symptoms such as weakness, palpitations or tingling, or severe cramps of recent onset.
In these cases, the doctor may request sodium, potassium, calcium, magnesium and creatinine tests and, depending on the circumstances, glucose, TSH, vitamin D or parathyroid hormone. Follow the laboratory's instructions when preparing to have the sample taken. Always mention any medicines and supplements you take.
Sodium, water and exercise-associated cramps
Of all the minerals in the fluid around our cells, sodium is present in the greatest quantity. Sweating can remove a considerable amount of it. For many years, loss of salt and water was thought to explain cramping during exercise, which is why salty drinks were advised. Newer research gives tired muscles at least equal importance, and studies disagree on whether keeping hydrated prevents cramp.
Low blood sodium (hyponatraemia) can occur with some diuretics and antidepressants, or in people who drink large amounts of water during prolonged exertion. Marked cases cause nausea, headache, confusion and, rarely, seizures, which require urgent assessment. Drinking excessive amounts of water 'to prevent cramps' is therefore not without risk.
Diet: what to expect
A varied diet generally provides enough magnesium, calcium and potassium. Sources of magnesium include pulses, nuts, seeds, wholegrain cereals and green leafy vegetables. Calcium comes mainly from dairy products, some fish with edible bones and green vegetables. Potassium is found in fruit, vegetables, potatoes and pulses.
Adjusting your diet is reasonable and safe for most people, but should not be expected to resolve idiopathic cramps. People with kidney disease should follow their doctor's advice about dietary potassium, as too much can be dangerous.
At Clínica Alegre in Setúbal and Seixal, you can have laboratory tests and ask our team any questions about the results.
Frequently asked questions
Should I take magnesium for cramps?
The evidence shows little or no benefit for ordinary cramps in older adults. Speak to your doctor before starting it.
Do bananas prevent cramps?
They are a good source of potassium, but there is no evidence that they prevent cramps in people with normal potassium levels.
My magnesium level is normal. Could I still be deficient?
It is possible, because blood levels do not reflect all the body's stores. Your doctor will assess this alongside your medical history.
Why was my potassium high if I feel well?
There may be laboratory causes, such as haemolysis. Your doctor will decide whether and how urgently it needs to be repeated.
Should pregnant women take magnesium for cramps?
Studies are conflicting. The decision rests with the doctor providing their care.
Do diuretics cause cramps by lowering mineral levels?
They can, by lowering potassium or magnesium. Do not stop taking your diuretic; speak to your doctor.
Did you enjoy this article?
Scientific references2
- Garrison SR, Korownyk CS, Kolber MR, et al. Magnesium for skeletal muscle cramps. Cochrane Database Syst Rev. 2020; 9(9):CD009402.
- Allen RE, Kirby KA. Nocturnal leg cramps. Am Fam Physician. 2012;86(4):350–5.





