| The short answer | Magnesium deficiency and muscle cramps are linked because magnesium helps muscles relax after they contract and keeps nerves from firing too easily. When it runs low, nerves turn over-excitable and muscles are slow to let go — felt as cramps, twitches, spasms and restless legs. |
| Where you feel it | Most often the calves, feet and eyelids, and often worst at night or after exercise. |
| What helps | Eat more magnesium-rich foods (seeds, nuts, leafy greens, beans, whole grains), stay hydrated, and consider a sensible supplement — while seeing a clinician about frequent or severe cramps. |
That sudden, gripping calf cramp in the middle of the night. The eyelid that flutters for days. The legs that will not stay still in the evening. These small, nagging complaints have many possible causes — but one of the most common and most fixable is a shortfall of a single mineral. The connection between magnesium deficiency and muscle cramps is well established, and it sits right at the meeting point of your muscles and your nerves.
Magnesium is involved in hundreds of processes in the body, but two of its jobs matter most here: it helps muscles relax after they fire, and it helps keep nerves from becoming over-excitable. When magnesium runs low, both of those brakes weaken — and the result is exactly the cramping, twitching, jumpy pattern so many people know. This guide explains the mechanism in plain language, shows you the warning signs, and lays out the food-first, sensible-supplement approach that helps — alongside a clinician's advice when symptoms are frequent or severe.
To understand the link, picture what happens when a muscle contracts. A nerve signal tells the muscle to fire; calcium floods into the muscle cells to make them contract; and then magnesium helps usher that calcium back out so the muscle can relax again. Magnesium is, in effect, the counterweight to calcium — the "off switch" that lets a tensed muscle release.
When magnesium is in short supply, that off switch is sluggish. Muscles stay contracted longer than they should, which you feel as a cramp or a lingering spasm. At the same time, magnesium normally helps stabilise nerve cell membranes, keeping them from firing at the slightest provocation. Low magnesium leaves nerves more excitable, so they send extra, unwanted signals — the little twitches and the restless, buzzing sensations. Cramps and twitches, in other words, are two faces of the same underlying problem: not enough of the mineral that helps everything settle down.
Cramps and twitches tend to favour the calves, feet and eyelids, and often strike at night or after exercise — when muscles are fatigued, circulation is quieter, and any mineral shortfall is most exposed. If a restless, can't-keep-still feeling in the legs is your main symptom, our guide on what causes restless legs at night looks at how magnesium fits alongside the other triggers.
Magnesium deficiency is easy to miss because its early signs are quiet and overlap with everyday life. Beyond cramps and twitches, low magnesium can show up as:
A blood test gives only a rough picture, because most of the body's magnesium is stored inside cells and bone rather than in the blood. That is why clinicians look at your symptoms, diet and risk factors together. It is also why a food-first approach is so reasonable: for most people, eating more magnesium-rich foods is safe and sensible whether or not a test shows a clear number.
Quiet Nerves™ provides magnesium alongside B-vitamins, alpha-lipoic acid, turmeric and traditionally calming botanicals — helping keep the mineral your muscles and nerves rely on topped up in one simple daily capsule, backed by a 60-day guarantee. It supports a magnesium-rich diet; it is not a treatment for a medical condition.
See Quiet Nerves Packages
Food is the first and safest place to top up magnesium, and the richest sources are easy to build into everyday meals:
Because magnesium works in partnership with other nerve nutrients — the B-vitamins, potassium and calcium — a broadly balanced plate serves you better than fixating on one food. Our overview of the best foods for nerve health shows how magnesium sits alongside them, and if your symptoms lean more toward tingling than cramping, it is worth ruling in or out a vitamin B12 shortfall too, since the two often travel together.
Food should come first, but modern diets often fall short of magnesium, and a sensible daily supplement can help close the gap — particularly for people whose cramps, twitches or restless legs point that way. Quiet Nerves supplies magnesium alongside the B-vitamins and botanicals that support calm, comfortable nerves, in a once-daily capsule. A note on doses: food sources are very safe, but supplemental magnesium in higher amounts can loosen the stool, and anyone with kidney problems should be cautious and follow medical advice. As with most nutrients, the goal is to meet your needs reliably, not to take very large amounts.
Nutrition does most of the work, but a few habits help too. Stay well hydrated, since dehydration and mineral loss go hand in hand. Stretch tight muscles gently, especially the calves before bed. Keep moving through the day to support circulation. And give your nervous system time to wind down in the evening — a calm routine reduces the wired, twitchy feeling that low magnesium can amplify.
See a clinician if cramps or twitching are frequent, severe, spreading, or come with weakness, numbness or muscle wasting, or if they disrupt your sleep or daily life. Cramps have causes beyond magnesium — from circulation to thyroid to medication side effects — that deserve proper assessment, and some drugs directly affect magnesium levels. Anyone with kidney disease should always take magnesium supplements only under medical guidance. This article is general information, not a diagnosis or treatment plan.
Yes, it can. Magnesium helps muscles relax after they contract and helps keep nerves from firing too easily. When magnesium is low, nerves can become over-excitable and muscles slower to relax, which can show up as cramps, twitches, spasms and a restless, jumpy feeling, often in the legs and feet. Restoring healthy magnesium levels through food and, where appropriate, a supplement often helps, though cramps have many causes.
Early signs can be subtle and include muscle cramps or twitches, a restless feeling in the legs, fatigue, low mood and poor sleep. Because these overlap with many other things, low magnesium is easy to miss. A blood test gives only a rough picture, since most magnesium is stored inside cells and bone, so clinicians look at symptoms, diet and risk factors together rather than relying on one number.
The richest sources are pumpkin and chia seeds, almonds and cashews, spinach and other leafy greens, black beans and legumes, whole grains, and dark chocolate. Building a few of these into everyday meals is the simplest way to keep magnesium topped up. Because modern processed diets are often low in these foods, many people fall short without realising it.
Adults generally need a few hundred milligrams a day, with exact amounts varying by age and sex. Food sources are very safe, but supplements can cause loose stools or stomach upset in higher doses, and people with kidney problems should be cautious and follow medical advice. As with most nutrients, the aim is to meet your needs reliably rather than to take very large amounts.
See a clinician if cramps or twitching are frequent, severe, spreading or accompanied by weakness, numbness or muscle wasting, or if they interfere with sleep or daily life. These can have causes beyond magnesium that need assessment, and some medications affect magnesium levels. This article is general information and not a diagnosis or a substitute for professional advice.
† These statements have not been evaluated by the FDA. This product is not intended to diagnose, treat, cure or prevent any disease. This article is for general information only and is not medical advice.