Key takeaways:
Many people take vitamin and mineral supplements to help with leg cramps at night. Popular choices include magnesium, quinine, and vitamin K.
Based on research, magnesium is unlikely to help with leg cramps. But vitamin K supplements may reduce the intensity, frequency, and duration of leg cramps.
Quinine used to be a popular solution. But it’s no longer recommended due to potentially life-threatening side effects.
If you’re one of the many people who experience leg cramps at night, you’ll probably do just about anything to get rid of them. And since it’s not always clear what causes these leg cramps in the first place, it’s hard to know what will help. So, people try anything from tonic water to pickle juice to help. But is there any science behind these home remedies?
We’ll take a deep dive on three popular options: magnesium, quinine, and vitamin K. And before taking a look at whether certain vitamins help, we’ll explore why leg cramps happen in the first place.
Leg cramps during the night — also called nocturnal leg cramps — happen for a variety of different reasons. And a lot of the time, they have no identifiable cause. But common causes include:
Exercise and fatigued muscles
Sitting, resting, or standing for long periods of time
Pregnancy
Increasing age, especially being over age 60, since tendons shrink as you get older
Electrolyte abnormalities, like high or low sodium
Neuromuscular conditions like amyotrophic lateral sclerosis (ALS)
Kidney and liver disease
Peripheral neuropathy, which is common in diabetes
Medications like naproxen, statins, diuretics, and inhaled medicines like salmeterol
If you’re deficient in one of the following vitamins, it may be contributing to nocturnal leg cramps:
Magnesium is a nutrient your body uses to regulate muscle and nerve function. Without it, your muscles are more likely to spasm and cramp. But this usually happens only if your levels are very low.
Vitamin D is also important for muscle function. And it helps you absorb calcium, which helps muscles properly contract and relax. Both low vitamin D and calcium lead to increased muscle cramps.
Vitamin B1 is also called thiamine. Your body uses it to produce energy. Low vitamin B1 can lead to a condition called beriberi, which causes leg pain and cramps.
Vitamin B12 supports blood and nerve health. Some small studies suggest that deficiency can cause muscle cramps.
The research suggests that magnesium doesn’t work for leg cramps. Several large review studies have looked into this. And all of them concluded that magnesium wasn’t helpful. This includes:
A review of 11 studies in doses ranging from 100 mg to 520 mg of oral magnesium daily
A review of 7 studies in doses ranging from 300 mg to 364 mg of oral magnesium daily
Another review of 7 studies of 900 mg of oral magnesium daily
Magnesium may help if you have low levels of magnesium to begin with. But if you’re otherwise healthy, you’re likely getting enough magnesium in the foods that you eat. And any extra won’t help with leg cramps.
The research on quinine suggests that it may help leg cramps. A review of the available evidence suggested it could be moderately helpful at doses around 300 mg a day. But the evidence was weak. And given the serious and potentially life-threatening side effects of taking quinine, experts don’t recommend it.
Quinine is a medicine that has been around since the 1930s. It’s also found in tonic water — 1 L of tonic water contains about 60 mg to 70 mg of quinine. But as of now, quinine is only approved by the FDA for the treatment of malaria.
Not sure what’s causing your leg cramps? Our experts review the common medications that can cause leg cramps — and other common causes.
What about pickle juice? We review whether pickle juice can help with leg cramps. And we cover other myths and truths about its health benefits.
Is tonic water good for you? If you want to take a deeper dive into the benefits and harms of quinine, we’ve got you covered.
In 2006, the FDA issued a warning about using quinine for leg cramps, stating that it wasn’t effective and could be dangerous. And since then, the FDA has continued to advise against its use for leg cramps given the potential life-threatening side effects like:
Low levels of platelets: Platelets help blood clot. With fewer platelets, there’s an increased risk of internal bleeding.
An exaggerated immune response: This can lead to organ damage.
Heart arrhythmias: This issue, also known as irregular heartbeats, can be life-threatening.
It’s particularly important to avoid quinine if you:
Take any medicines that prevent blood clotting
Have heart, liver, or kidney disease
Are pregnant or plan to become pregnant, since quinine can harm a developing baby
It’s possible that vitamin K may help leg cramps. But to date, not much research has been done.
The term “vitamin K” is used to describe a group of compounds, including K1 and K2. Vitamin K1 is found in green leafy vegetables. Vitamin K2 is listed as menaquinone-4 or menaquinone-7 in supplements. It's found in animal products. The limited research on vitamin K and leg cramps has focused on vitamin K2.
One large study found that people ages 65 and older who took 180 mcg of vitamin K2 had less leg cramps at night compared to placebo. Scientists reached the same conclusions in people on hemodialysis (a kidney disease treatment) who took 360 mcg daily of vitamin K2 for 4 weeks.
There isn’t a formal upper limit on how much vitamin K you can take. But avoid taking extra vitamin K if you take any blood thinners like warfarin. Too much vitamin K can interfere with how well warfarin works. And this can make it more likely for you to develop blood clots.
Leg cramps can be a real pain, especially if they prevent you from getting sleep. And while it may be tempting to reach for supplements, there isn’t much data to support using them. Also, supplements like vitamin K and quinine can have some serious side effects for certain groups of people.
Allen, R. E., et al. (2012). Nocturnal leg cramps. American Family Physician.
Bordoni, B., et al. (2023). Muscle cramps. StatPearls.
Delacour, C., et al. (2020). Association between physical activity and nocturnal leg cramps in patients over 60 years old: A case-control study. Scientific Reports.
El-Tawil, F., et al. (2015). Quinine for muscle cramps. Cochrane Database of Systematic Reviews.
FDA News for Health Professionals. (2012). Serious risks associated with using quinine to prevent or treat nocturnal leg cramps. U.S. Food and Drug Administration.
Frusso, R., et al. (1999). Magnesium for the treatment of nocturnal leg cramps: A crossover randomized trial. The Journal of Family Practice.
Garrison, S. R., et al. (2012). Magnesium for skeletal muscle cramps. Cochrane Database of Systematic Reviews.
Garrison, S. R., et al. (2012). Nocturnal leg cramps and prescription use that precedes them: A sequence symmetry analysis. JAMA Internal Medicine.
Johnson, L. E. (2024). Thiamin deficiency. Merck Manual Consumer Version.
Moretti, A. (2021). What is the role of magnesium for skeletal muscle cramps? A Cochrane Review summary with commentary. Journal of Musculoskeletal and Neuronal Interactions.
Office of Dietary Supplements. (2021). Magnesium: Fact sheet for consumers. National Institutes of Health.
Office of Dietary Supplements. (2021). Thiamin: Fact sheet for consumers. National Institutes of Health.
Office of Dietary Supplements. (2021). Vitamin D: Fact sheet for consumers. National Institutes of Health.
Saguil, A., et al. (2016). Quinine for leg cramps. American Family Physician.
Tan, J., et al. (2024). Vitamin K2 in managing nocturnal leg cramps: A randomized clinical trial. JAMA Internal Medicine.
U.S. Food and Drug Administration. (2006). Drug products containing quinine; enforcement action dates. Federal Register.
Wolffenbuttel, B. H. R., et al. (2019). The many faces of cobalamin (vitamin B12) deficiency. Mayo Clinic Proceedings: Innovations, Quality & Outcomes.
Xu, D., et al. (2022). Vitamin K2 as a potential therapeutic candidate for the prevention of muscle cramps in hemodialysis patients: A prospective multicenter, randomized, controlled, crossover pilot trial. Nutrition.
Young, G. (2015). Leg cramps. BMJ Clinical Evidence.