What causes leg cramps during pregnancy, and can they be prevented?

Answer From Mary Marnach, M.D.

Leg cramps are painful muscle contractions that typically affect the calf, foot or both. They are common during pregnancy, often happening at night during the second and third trimesters.

While the exact cause of leg cramps during pregnancy isn't clear, you can take steps to prevent them.

  • Stretch your calf muscles. Stretching before bed might help prevent leg cramps during pregnancy. Stand at arm's length from a wall. Place your hands on the wall in front of you and move your right foot behind your left foot. Slowly bend your left leg forward, keeping your right knee straight and your right heel on the floor. Hold the stretch for about 30 seconds. Keep your back straight and your hips forward. Don't shift your feet inward or outward. Switch legs and repeat.
  • Stay active. Regular physical activity might help prevent leg cramps during pregnancy. Before you begin an exercise program, talk to your health care provider to make sure it's safe for you.
  • Drink plenty of fluids. Keeping your muscles hydrated might help prevent cramps. When you're drinking enough fluids, your urine should be clear or light yellow in color. If urine is darker yellow, it might mean that you're not getting enough water.
  • Get your calcium. Some research suggests that lower levels of calcium in the blood during pregnancy could contribute to leg cramps. If you're pregnant or could become pregnant, get 1,000 milligrams of calcium a day.
  • Consider a magnesium supplement. Although the evidence from research studies is mixed, taking a magnesium supplement might help prevent leg cramps during pregnancy. Talk to your health care provider before you take a supplement. You also might consider eating more magnesium-rich foods, such as whole grains, beans, dried fruits, nuts and seeds.
  • Wear the right shoes. Pick shoes that are comfortable and provide good support for your feet. It might help to wear shoes with a firm heel counter. That's the part that surrounds the heel and helps secure the foot in the shoe.

If you get a leg cramp, stretch the calf muscle. Walking and then sitting and raising your legs might help keep the leg cramp from coming back. A hot shower, warm bath, ice massage or muscle massage may help too.

If leg cramps keep coming back or if they are severe during pregnancy, talk to your health care provider about possible treatment options.


Mary Marnach, M.D.

From Mayo Clinic to your inbox

Sign up for free and stay up to date on research advancements, health tips, current health topics, and expertise on managing health. Click here for an email preview.

To provide you with the most relevant and helpful information, and understand which information is beneficial, we may combine your email and website usage information with other information we have about you. If you are a Mayo Clinic patient, this could include protected health information. If we combine this information with your protected health information, we will treat all of that information as protected health information and will only use or disclose that information as set forth in our notice of privacy practices. You may opt-out of email communications at any time by clicking on the unsubscribe link in the e-mail.

April 12, 2023 See more Expert Answers