Singapore & Southeast AsiaEvidence-based · Plain English · Free to read
A patient's guide to vein health The Vein GuideVein health, explained clearly 95 guides · Free to read
Understanding Conditions

Leg Cramps at Night: Causes, Quick Relief and Prevention

Why leg cramps at night happen, how to stop a calf cramp quickly, how to help prevent them and when cramps point to a vein, circulation or nerve problem that needs a doctor.

Close view of a man's bare calf gripped by both hands while he stands bent forward on grass in sneakers

If a sudden, hard, painful knot in your calf has ever jolted you awake, you know how sharp leg cramps at night can be. They are common, usually harmless and over within minutes, but they can leave you sore and sleepless. This page explains what they are, what may cause them, how to ease one quickly and how to lower your chances of getting them. It is educational and cannot diagnose you.

Emergency signs. Call 995 if a leg suddenly becomes cold, pale, blue or numb, or if leg pain comes with chest pain, breathlessness or coughing up blood. See a doctor the same day if one leg is swollen, warm, red and painful.

What are leg cramps at night?

A cramp is an involuntary, painful tightening of a muscle. In the legs it most often affects the calf, but it can also hit the thigh, the sole of the foot or the toes. Many people ask about leg cramps during sleep, leg cramps in sleep or leg cramps while sleeping; these all describe the same thing: a spasm that wakes you, then eases over seconds to several minutes. The muscle may feel hard and look knotted, and may stay tender for hours afterwards. The old name “charley horse” is also used for a sudden muscle cramp or spasm.

What causes leg cramps?

For many people, no cause is found. These are described as idiopathic cramps. Things that are often linked to calf cramps include:

  • Tired or overused muscles after exercise or a long day on your feet
  • Sitting or lying in one position for long periods, or sleeping with the feet pointing down
  • Muscle tightness, especially in the calf
  • Ageing, as muscles and nerves change
  • Pregnancy, particularly the later months
  • Dehydration or heavy sweating, relevant in hot, humid weather
  • Some medicines. Ask your doctor or pharmacist if cramps began after starting a new tablet, and do not stop a prescribed medicine on your own
  • Medical conditions such as diabetes, thyroid problems, kidney disease, liver disease, nerve conditions or alcohol-related problems

Cramps in feet and toes

Foot cramps and cramps in feet are usually the same kind of muscle spasm, often curling the toes or arching the foot. They tend to follow tight or unsupportive footwear, long walks, or sleeping with the feet pointed. Stretching the toes upward and standing on a cool floor often helps.

How to stop leg cramps immediately

When a cramp strikes, the aim is to lengthen and relax the muscle.

  1. Stretch it. Straighten the leg and pull your toes and foot up toward your shin. Hold until the muscle softens.
  2. Stand and put weight on it. Press your foot flat on the floor, then take a few slow steps.
  3. Massage gently. Rub the muscle once the worst of the spasm eases.
  4. Use warmth. A warm cloth or shower can help the muscle relax afterwards. Cool packs help some people with lingering soreness.
  5. Slow your breathing. Tension makes spasms feel worse.

Do not pound or knead hard on a calf that is also swollen, warm and tender, because that could be a blood clot and needs checking first.

How to prevent cramps

There is no guaranteed method, and the research on prevention is mixed. These steps are low risk and may help:

  • Stretch your calves gently for a minute or two before bed.
  • Stay active during the day and avoid long spells of sitting or standing still.
  • Drink enough fluids, especially in hot weather or after exercise.
  • Choose supportive, comfortable shoes and avoid sleeping with your feet pointing hard downward; loosen tight bedclothes.
  • Build up exercise gradually rather than suddenly.
  • Check with your doctor before taking any supplement or medicine for cramps. The evidence is limited, and some products can have side effects.

When cramps point to veins or circulation

Most cramps are muscular, but legs that cramp often alongside other symptoms can be a clue to something else.

Veins. Night cramps, aching, heaviness, ankle swelling, restless legs and itchy skin can occur together in venous disease. If you have visible varicose veins or swollen ankles, consider chronic venous insufficiency. Our vein symptom check can help you decide whether to ask for an assessment. Our wider guide to leg pain at night compares the possible causes.

Arteries. Cramping pain in the calf with walking that eases with rest, cold feet, hair loss on the legs or sores that heal slowly can reflect narrowed arteries. See leg pain when walking. Pain at rest in the foot at night also needs a medical check.

Nerves. Burning, tingling or numbness, or weakness, suggest a nerve cause such as irritation of a nerve from the back or diabetes-related nerve damage.

Restless legs. If the main issue is an urge to move the legs rather than a hard painful knot, see restless leg syndrome.

Blood clot. A clot (deep vein thrombosis) can cause calf pain that is sometimes mistaken for a cramp. Clues are swelling, warmth, redness and pain that does not ease with stretching, usually in one leg. See blood clot in leg symptoms.

When to see a doctor

Call 995 immediately if:

  • A leg suddenly turns cold, pale, blue or numb
  • Leg pain comes with chest pain, breathlessness or coughing up blood

Seek care the same day if one calf is swollen, warm, red or painful and the pain does not ease with stretching, or if red skin is spreading with fever.

Book a visit soon if you are asking when to worry about leg cramps and any of these apply: cramps are frequent, severe or waking you most nights; they began after a new medicine; you also have swelling, numbness, weakness, visible veins or skin changes; or cramps are not settling with the steps above. Your GP can review your medicines, check blood tests and examine your legs, and may refer you to a vein or vascular specialist; see find a vein specialist. Unfamiliar terms are explained in the glossary.

This page is educational and does not replace personal medical advice.

Frequently asked questions

What is a charley horse?

It is a common name for a sudden muscle cramp or spasm, most often in the calf. It can also mean a deep bruise from a knock to the thigh. The usual night-time kind is a muscle spasm that settles within minutes, though soreness may last longer.

How do I stop a leg cramp immediately?

Stand up and put weight on the leg, or sit and pull your toes up toward your shin to stretch the calf. Walking slowly around helps. Once it eases, gentle massage and warmth can relax the muscle.

Why does my leg always cramp at night?

Repeated cramps may relate to tired or overworked muscles, long periods of standing or sitting, ageing, pregnancy, dehydration, certain medicines or medical conditions such as nerve, thyroid, kidney or vein problems. If it keeps happening, it is worth seeing a doctor rather than guessing.

Do varicose veins cause leg cramps?

They can be linked. People with venous disease often report night-time cramps, aching and restless legs, though cramps are also very common in people with healthy veins. A vein check can help if you also have swelling, visible veins or heavy legs.

When should I worry about leg cramps?

See a doctor if cramps are frequent, severe, not helped by stretching, linked with weakness, numbness, swelling, skin changes or a new medicine, or if one leg is swollen, red or warm. Urgent signs include a sudden cold, pale or numb leg. Call 995.

Sources and further reading

  1. NHS — Leg cramps
  2. NHS — Peripheral arterial disease
  3. NHS — Deep vein thrombosis
  4. NICE Guideline CG168: Varicose veins — diagnosis and management

This article is general information, not personal medical advice. Please speak to a doctor about your own symptoms. How we create our content.