Supplements for Muscle Cramps: What Works and What Doesn’t

No single supplement reliably prevents muscle cramps for everyone, and several popular options have weaker evidence than you’d expect. The best-supported approaches focus on maintaining electrolyte balance, particularly sodium and potassium, rather than megadosing any one mineral. Here’s what the research actually shows for the most common supplements people try.

Magnesium: Popular but Disappointing

Magnesium is the supplement most people reach for when cramps strike, but clinical trials tell a different story. A Cochrane review of 11 trials involving 735 patients found that magnesium supplementation (ranging from 100 to 520 mg of elemental magnesium daily) did not significantly reduce cramp frequency, intensity, or duration compared to placebo over one month. The certainty of this evidence was rated moderate to high, meaning it’s unlikely that future studies will reverse the finding.

The review’s authors concluded that magnesium supplementation is unlikely to help with the most common type of cramp: idiopathic cramps, meaning those without a clear underlying cause, including the nighttime leg cramps that plague older adults. Evidence for pregnancy-related cramps was conflicting and too weak to draw conclusions from.

That said, if you’re genuinely deficient in magnesium, correcting that deficiency is still worthwhile for overall muscle and nerve function. The recommended daily intake is 400 to 420 mg for adult men and 310 to 320 mg for adult women, depending on age. The NIH sets a tolerable upper limit of 350 mg specifically from supplements (food sources don’t count toward this cap). Going above that threshold increases the risk of diarrhea and digestive discomfort, which is often the first sign you’re taking too much.

Electrolytes Matter More Than Any Single Pill

The bigger picture for cramp prevention isn’t about one mineral. It’s about the balance between sodium, potassium, and chloride in your blood. A study published in BMJ Open Sport & Exercise Medicine demonstrated this clearly: after dehydrating participants through exercise, researchers gave one group plain water and another group an oral electrolyte solution. The plain water group saw their blood sodium drop to about 138 mmol/L and became significantly more susceptible to cramps. The electrolyte group maintained sodium around 142 mmol/L and stayed at baseline cramp susceptibility.

Potassium followed the same pattern. It dropped in the water-only group but held steady in the electrolyte group. This highlights something counterintuitive: drinking large amounts of plain water after heavy sweating can actually make cramps worse by diluting the electrolytes in your blood. If you’re exercising hard or sweating heavily, an electrolyte drink or adding sodium and potassium to your water is more protective than water alone.

For practical purposes, potassium-rich foods (bananas, potatoes, avocados, beans) and adequate salt intake cover most people’s needs. If you supplement potassium directly, keep in mind that over-the-counter potassium supplements are typically capped at 99 mg per pill, a fraction of the 2,600 to 3,400 mg daily recommendation, precisely because excess potassium can cause dangerous heart rhythm problems. Food is the safer route.

B Vitamins Show Promise in Small Studies

A randomized, double-blind trial tested a vitamin B complex (containing B1, B2, B6, and B12) in 28 elderly patients with severe nocturnal leg cramps. After three months, 86% of those taking the B complex reported prominent remission of their cramps, while the placebo group showed no meaningful change. The supplement reduced cramp frequency, intensity, and duration.

This is encouraging but comes with a major caveat: 28 people is a very small study, and it specifically looked at elderly patients with high blood pressure. Whether B vitamins help younger, healthier people with occasional cramps is unknown. Still, B complex supplements are inexpensive, generally safe at standard doses, and worth considering if nighttime cramps are a persistent problem, particularly for older adults.

Vitamin D Doesn’t Help

Vitamin D is often mentioned alongside magnesium for muscle health, but a well-designed trial in 230 postmenopausal women found it had no effect on muscle cramps. Women received either high-dose vitamin D, low-dose vitamin D, or placebo. Even though the supplemented groups achieved blood levels above 30 ng/mL (considered fully replete), cramp rates were virtually identical across all three groups. The researchers found that dietary potassium intake was a much stronger predictor of who got cramps than vitamin D status.

Creatine May Reduce Cramps in Athletes

This one surprises most people because creatine has a lingering reputation for causing cramps, but the data suggests the opposite. A study of collegiate football players found that creatine users experienced significantly less cramping than non-users over the course of a season. A related three-year study of 100 Division I football players confirmed these findings: creatine users had similar or lower rates of cramping, dehydration, muscle tightness, and muscle strains compared to non-users.

Creatine helps muscles retain water intracellularly, which may support better hydration at the cellular level. If you’re an athlete or someone who exercises regularly and deals with cramps, creatine monohydrate (typically 3 to 5 grams daily) is a reasonable option that carries other performance benefits as well.

Pickle Juice: Not a Supplement, but It Works Fast

Pickle juice has a strong following among athletes, and research backs it up for stopping cramps once they’ve started. A study on dehydrated participants found that pickle juice inhibited electrically induced muscle cramps within seconds. Critically, this happened far too quickly to be explained by rehydration or electrolyte absorption. The researchers concluded that something in the vinegar triggers a reflex in the mouth and throat that signals the nervous system to shut down the overactive nerve firing causing the cramp.

This makes pickle juice (or any strong vinegar-based liquid) useful as an acute remedy rather than a preventive supplement. About one to two ounces at the onset of a cramp is the typical amount people use. Mustard works through a similar mechanism.

What to Avoid: Quinine

Quinine, found in tonic water and previously prescribed for nighttime leg cramps, carries serious risks. The FDA issued a specific safety communication warning against using quinine for cramps after continued reports of life-threatening side effects. These include a severe drop in platelet count (cells that help your blood clot), which led to hospitalizations and, in some cases, death. Among 38 adverse event reports the FDA reviewed, 21 patients required hospitalization for dangerously low platelet counts, and two patients died.

The amount of quinine in tonic water is lower than in prescription tablets, but the FDA’s position is clear: quinine should not be used for leg cramps at any dose. The risk of serious bleeding, kidney damage, and hearing loss far outweighs any potential benefit for a non-life-threatening condition.

Putting It Together

If you’re dealing with frequent cramps, the most evidence-supported approach is maintaining overall electrolyte balance rather than relying on a single supplement. That means getting enough sodium and potassium through your diet, using electrolyte drinks rather than plain water during heavy exercise, and ensuring your magnesium intake meets the daily recommendation through food first. For nighttime cramps in older adults, a B complex vitamin has limited but positive evidence. Athletes may benefit from creatine. And for cramps that have already started, a shot of pickle juice or vinegar is the fastest intervention available.