Why Do My Legs Hurt After a Colonoscopy?

Leg pain after a colonoscopy is usually caused by one of three things: muscle cramping from electrolyte losses during bowel prep, stiffness from lying in one position while sedated, or minor nerve compression from how your legs were positioned during the procedure. Most of these resolve on their own within a day or two, but certain types of leg pain deserve prompt attention.

Bowel Prep Can Drain Your Electrolytes

The most common reason for leg aching or cramping after a colonoscopy has nothing to do with the procedure itself. It starts with the prep. The powerful laxatives you drink the night before flush out more than stool. They pull water and minerals from your body, and those mineral losses can make your muscles cramp, feel weak, or ache.

Potassium takes the biggest hit. A meta-analysis in Digestive Endoscopy found that sodium phosphate-based preps dropped potassium levels by an average of 0.58 mmol/L, while the more common polyethylene glycol (PEG) preps caused a smaller but still measurable drop of 0.25 mmol/L. Magnesium and calcium also dip slightly. When potassium and magnesium fall, your muscles are more prone to cramping and soreness, especially in the large muscle groups of your legs. Add in the general dehydration from hours of diarrhea and fasting, and it’s no surprise your legs feel off.

This type of pain tends to feel like generalized soreness or intermittent cramping in both legs. Rehydrating and eating potassium-rich foods (bananas, potatoes, avocados) typically clears it up within 24 hours.

Positioning While You’re Sedated

During a colonoscopy, you’re lying on your side (usually the left) for anywhere from 15 to 45 minutes while sedated. Because the sedation keeps you still, you aren’t making the small shifts in position your body normally makes to keep blood flowing and relieve pressure on joints and muscles. That prolonged immobility can leave you feeling stiff and sore, especially in your hips, knees, and lower back.

Some colonoscopies also involve repositioning you partway through the procedure, sometimes into a “frog leg” position or briefly onto your back. These changes can stretch or compress muscles and ligaments in ways you wouldn’t tolerate while awake. Because the sedation suppresses your pain reflexes, you don’t instinctively pull away from an uncomfortable position the way you would during sleep. The result is muscle soreness that shows up once the sedation wears off, similar to how you might feel after sleeping in an awkward position on an airplane, only more pronounced.

Nerve Compression at the Knee

A less common but more noticeable cause is compression of the peroneal nerve, which runs along the outside of your leg just below the knee, right where it wraps around a bony bump called the fibular head. When your leg rests against a hard surface or a positioning device during the procedure, pressure on this spot can temporarily damage the nerve.

Peroneal nerve compression feels different from ordinary soreness. Instead of a general ache, you may notice numbness or tingling from the knee down to the foot, weakness when trying to lift your foot upward (called foot drop), or a pins-and-needles sensation along the outer shin. One case report in the Journal of the Canadian Association of Gastroenterology documented a patient who lost sensation from the left knee to the sole of the foot immediately after colonoscopy, with electrodiagnostic testing confirming a compression injury at the fibular head. Higher BMI and longer procedure times appear to increase the risk.

Motor nerve injuries during colorectal procedures are rare, occurring in roughly 0.065% of cases based on a large national database analysis. When they do happen, most are caused by demyelination (temporary disruption of the nerve’s insulating layer) rather than permanent damage, and sensation and strength typically return over weeks to months.

Gas Tracking Along the Psoas Muscle

During colonoscopy, air or carbon dioxide is pumped into your colon to inflate it for visibility. Occasionally, small amounts of that gas can escape through the bowel wall into the surrounding tissue, even without a true perforation. When gas tracks into the retroperitoneal space (the area behind the abdominal cavity), it can migrate along the psoas muscle, a deep hip flexor that runs from your lower spine to your inner thigh.

This produces a distinctive pattern: left-sided abdominal pain combined with thigh pain that worsens when you extend or straighten the leg. A case report in the Annals of Coloproctology described exactly this scenario in a patient one day after a polypectomy. CT imaging showed free air bubbles along the psoas muscle with no visible perforation. This is uncommon, but it’s worth knowing about because the pain pattern (deep thigh pain worsening with movement, paired with abdominal pain) is a signal that something beyond routine soreness is going on.

Blood Clots: A Rare but Serious Possibility

Deep vein thrombosis is an uncommon but real risk after colonoscopy. A study in Clinical Gastroenterology and Hepatology found that thromboembolic events occurred in about 0.32% of patients. The risk was highest for people who had to temporarily stop blood-thinning medications before the procedure. Patients who paused two or more blood thinners had a rate of 4.55%, and those who stopped a single agent like clopidogrel had a rate around 3%.

A blood clot in the leg typically causes pain in one leg only, along with swelling, warmth, and redness, often concentrated in the calf. The affected leg may look noticeably larger than the other. This is different from the bilateral, generalized soreness of dehydration or positioning stiffness. If your leg pain is one-sided, swollen, warm to the touch, or getting worse rather than better over the first day or two, that combination warrants urgent evaluation.

What Normal Recovery Looks Like

Mild, symmetrical leg soreness or cramping that starts within hours of the procedure and fades as you rehydrate and move around is the most common pattern. Most people feel back to normal within one to two days. Gentle walking, drinking plenty of fluids, and eating mineral-rich foods speed this along.

Pain that is severe, worsening, or limited to one leg stands apart from routine recovery. The same goes for numbness that doesn’t improve, inability to lift your foot, a swollen or discolored leg, or thigh pain that gets worse when you straighten the leg. Any of these patterns suggest something beyond the expected aftermath of prep and positioning.