What Causes Muscle Cramps? Why Muscles Suddenly Lock Up
A muscle cramp is a sudden, painful contraction you can’t control. What science says about the causes, why stretching helps and how to prevent night cramps.
Short answer
A muscle cramp is a sudden, involuntary and often painful contraction of a muscle that does not relax. For a long time cramps were blamed mainly on dehydration and loss of salts such as sodium and potassium. Research on exercise-associated cramps now points more strongly to a problem in the nerve control of tired muscles: signals that tell the muscle to contract become too strong, while signals that tell it to relax become too weak. Stretching the muscle usually stops a cramp within seconds. Night-time leg cramps are common, especially in older people, and frequent cramps should be checked by a doctor.
In this article (6)
You are in the last kilometres of a run, or fast asleep, when suddenly your calf turns rock hard and the pain makes you gasp. You cannot relax the muscle no matter how hard you try. Muscle cramps are one of the most common aches people experience, yet scientists are still debating exactly why they happen.
What a cramp is
Normally, muscles contract when nerves tell them to, then relax when the signal stops. In a cramp, a muscle or part of one contracts strongly on its own and stays contracted, from a few seconds to several minutes. The calf is the classic spot, but cramps also strike the thighs, feet, hands and other muscles.
Two explanations
1. Dehydration and electrolytes. The traditional explanation, going back more than a century to labourers cramping in hot mines and ships, is that sweating out too much water and salt upsets the balance of minerals around nerves and muscles. Very large losses of fluid and salt can indeed cause cramps in some situations.
2. Neuromuscular fatigue. Many sports scientists now favour a different explanation for cramps during exercise. Studies of athletes have often found that those who cramp are no more dehydrated and have similar salt levels to those who don’t. Instead, cramps tend to strike tired muscles that are working hard, often in a shortened position. Fatigue appears to upset the balance of nerve signals in the spinal cord: signals that excite the muscle grow stronger, while signals that would normally make it relax grow weaker. The result is a muscle stuck “on”.
A 2021 review of the evidence concluded that this neuromuscular explanation fits best for most exercise cramps, though both factors may play a role in some cases.
What to do when a cramp strikes
Stretching the cramping muscle is the quickest and most reliable fix. For a calf cramp, straighten your leg and pull your toes towards you. Stretching activates sensors in the tendon that send “relax” signals back to the muscle. Gentle massage and warmth can help afterwards.
Interestingly, some small studies found that a sip of pickle juice can shorten cramps within about a minute, much too quickly for its salt to have been absorbed. That supports the idea that cramps are controlled by nerves: the strong taste may trigger a reflex that calms the overactive signals.
Night cramps
Leg cramps at night are very common, especially in people over 50 and during pregnancy. They may be linked to fatigued or shortened muscles, long periods of sitting, sleeping with the toes pointed, and some medicines, such as certain diuretics. Gentle calf stretches before bed may help. Magnesium supplements are widely recommended, but reviews have found they generally do not prevent typical cramps in older adults.
Preventing cramps
There is no guaranteed method, but these may help:
- Train gradually, so muscles are prepared for the effort you ask of them.
- Stretch regularly, especially the calves and thighs.
- Drink sensibly and replace salt during very long exercise in the heat.
- Pace yourself in races; cramps often hit when you push beyond your usual effort.
Frequent cramps without an obvious reason, or cramps with weakness, swelling or numbness, should be checked by a doctor.
In short
- A cramp is a sudden, involuntary contraction of a muscle that won’t relax.
- The old explanation is dehydration and salt loss; it can matter in some cases.
- Research now points mainly to nerve control problems in tired muscles.
- Stretching the muscle is the fastest way to stop a cramp.
- Night cramps are common, especially in older people and in pregnancy.
- Frequent or unusual cramps should be checked by a doctor.
Frequently asked questions
Are cramps caused by a lack of magnesium?
Magnesium is often recommended, but reviews of the evidence have found that magnesium supplements generally do not prevent typical muscle cramps in older adults. They may help in specific situations, such as pregnancy, but evidence is mixed.
Why do I get leg cramps at night?
Night cramps are common, especially in the calves and in people over 50. Causes may include muscle fatigue, long periods of sitting, shortened muscles while lying with pointed toes, some medicines and certain medical conditions.
Does drinking water prevent cramps?
Staying hydrated is important for health, but studies show athletes who cramp are often no more dehydrated than those who don’t. Fluids alone may not prevent exercise-associated cramps.
When should I see a doctor about cramps?
If cramps are very frequent, severe, do not improve with stretching, come with muscle weakness or swelling, or are not linked to exercise, it is worth getting checked.
Sources
- Miller, K. C. et al. (2021). An evidence-based review of the pathophysiology, treatment, and prevention of exercise-associated muscle cramps. Journal of Athletic Training
- Nelson, N. L. & Churilla, J. R. (2016). A narrative review of exercise-associated muscle cramps. Muscle & Nerve
- MedlinePlus – Muscle cramps
This article is based on peer-reviewed research and publications from trusted institutions, and it is reviewed regularly. How we work →