American Health & Medical Research Association
Practical guide

Bedtime stretching helps sleep a little, and its clearest use is for leg cramps

Small trials suggest gentle stretching and yoga can improve sleep modestly, and one trial found bedtime calf stretches cut night cramps. This is a 10-minute routine, a cramp plan and who should adapt it.

Sources15, listed below Reading time15 minutes

Where the evidence stands

  • Promising but early A regular stretching habit eases insomniaYoga or tai chi improves sleepBedtime calf and hamstring stretches reduce night cramps
  • Not enough evidence Stretching right at bedtime works better than at other timesStretching a muscle stops a cramp in progress
  • Evidence says no, or unsafe Magnesium prevents typical night crampsQuinine for night cramps

Each use is rated separately, from the scorecard in this guide. Safety cautions are spelled out in the guide itself. How we grade

On this page
  1. Night cramps have the best bedtime-stretching trial
  2. Quinine was once the cramp pill. The FDA now warns against it
  3. Is it a cramp, restless legs or something else?
  4. Stretching for insomnia: one small trial, and not at bedtime
  5. A 2025 review of 22 trials used stretching as the yardstick
  6. A 10-minute bedside and in-bed routine
  7. Adjust the routine if any of these apply
  8. What the evidence shows
  9. Questions readers ask
  10. The bottom line

Key takeaways

  • In a Dutch trial of 80 adults over 55, six weeks of stretching the calves and hamstrings right before bed cut nightly leg cramps by about 1.2 more than in a group that didn’t stretch5.
  • In a small Brazilian trial of adults with chronic insomnia, four months of stretching classes eased insomnia about as much as weight training, but the classes ran in the late afternoon, not at bedtime1.
  • A 2025 analysis of 22 insomnia trials found the clearest gains for yoga, tai chi and walking, and it treated plain stretching as a comparison group rather than a treatment23.
  • The FDA warned in 2010 that the malaria drug quinine should not be used for nighttime leg cramps, after reports of serious blood reactions that included two deaths9.
  • With osteoporosis, a small 1984 study and a few case reports argue for skipping rounded-back forward bends; after a hip replacement, follow your own surgeon’s rules on bending and crossing your legs1213.

Every night for six weeks, a group of adults over 55 did the same thing before climbing into bed: they stretched the backs of their calves and thighs. A second group, also troubled by night cramps, skipped the stretches5.

Both groups kept a diary of every cramp and rated the pain5. By the end, the stretchers’ nightly cramp count had fallen by about 1.2 more than the other group’s, and their cramps hurt less5.

That’s welcome news, because night leg cramps are common. Between 50% and 60% of adults report them, an average episode lasts about nine minutes, and they’re linked to insomnia7.

The evidence that stretching helps you sleep in general is thinner, and a little surprising. In a major 2025 analysis of insomnia trials, plain stretching was counted as a comparison group rather than a treatment3. We walk through what bedtime stretching can and can’t do, and how to do it safely.

Night cramps have the best bedtime-stretching trial

A night leg cramp is a sudden, painful tightening of a muscle, most often in the back of the calf, though the foot and thigh can cramp too7. Cramps get more common with age and are slightly more common in women7.

The cramp trial came from researchers at Hanze University of Applied Sciences in the Netherlands, published in 2012 in the Journal of Physiotherapy5. They recruited 80 adults over 55 who had night cramps and weren’t taking quinine, and all 80 finished5. A chance draw decided who would stretch nightly and who would carry on as usual5.

PEDro, a database that rates physical therapy trials, gave the study 8 out of 10 for design6. Its main weakness is one most exercise trials share: the people doing the stretches knew they were in the stretching group6. Knowing you’re “treated” can shape how you rate your own pain.

Other research cuts the other way. An earlier trial, published in 2005, enrolled 191 people over 60 who had been taking quinine for their cramps. Calf stretches three times a day for 12 weeks did no better than sham exercises, a fake routine7810.

A 2017 summary in American Family Physician (AFP) gave stretching its weakest strength grade, citing mixed results8. A 2012 AFP review still called stretching and deep massage low-risk options that people may try7. New Zealand’s best-practice journal for doctors took a similar view10.

Our reading: bedtime stretching is cheap, safe for most people and has one good trial behind it. It’s worth a six-week test.

Quinine was once the cramp pill, and the FDA now warns against it

Quinine, a malaria drug, used to be recommended for night cramps. Its benefit is modest but real: a 2017 AFP summary gave its effect on cramps the top evidence grade while noting that it’s no longer recommended78.

The trouble is safety. In 2010, the FDA required a Medication Guide and a formal risk plan for Qualaquin, a prescription quinine pill. The agency’s message was blunt: “Qualaquin should not be used for night time leg cramps”9.

The FDA had reviewed 38 serious reports filed from 2005 to 2008. Twenty-four involved blood problems, including two deaths, and 21 people needed hospital care for low platelets, the cells that help blood clot9. Most of the 38 had taken quinine for leg cramps or restless legs9. The FDA also warned that a rare blood disorder tied to quinine can, in some cases, leave permanent kidney damage9.

In 2007, New Zealand’s drug regulator, Medsafe, decided quinine’s risks no longer justified its use for leg cramps, and makers had to drop that use10. The drug is approved in the U.S. only for one type of malaria9.

Magnesium is the other popular fix, but reviews found no good evidence that it prevents typical night cramps8. Results in pregnancy are mixed10. Our magnesium article covers it in depth. Over-the-counter “anti-cramp” products also lack evidence10.

Is it a cramp, restless legs or something else?

Leg trouble at night comes in different forms, each with its own fix.

A cramp is a visible, rock-hard knot with sudden, sharp pain7. Restless legs syndrome is an urge to move your legs, usually in the evening, that eases when you move, without pain or a tight muscle7.

Even so, studies show the two can be hard to tell apart7. Our upcoming restless-legs article covers it.

Some medicines are linked to cramps, though it’s a rare side effect overall. AFP’s review lists the bone drugs raloxifene and teriparatide, estrogen hormone therapy, the pain reliever naproxen and iron given by IV7. Don’t stop a prescription on your own, but do ask your prescriber or pharmacist whether a change makes sense.

Stretching for insomnia: one small trial, and not at bedtime

The best test of stretching for insomnia comes from Brazil. Researchers there enrolled adults aged 30 to 55 who’d had insomnia for at least six months, then reported results for 28 of them in 20191.

Some took stretching classes, some lifted weights, and some had no program1. The classes met three times a week for four months, from 5 to 6 p.m., and each hour began with a five-minute walk followed by 45 minutes of gentle stretches for the arms and legs1.

Both exercise groups improved. On a standard insomnia questionnaire, stretchers’ scores fell about 8 points and lifters’ about 10.5, while the no-program group got slightly worse1. A wrist motion sensor showed stretchers fell asleep about 5 minutes faster and spent about 7 fewer minutes awake at night1. Stretchers also reported less tension and anxiety1.

Now the limits. The no-program group wasn’t chosen by chance: it was made up of people who couldn’t attend classes1. A one-night brain-wave sleep study found no differences1. And the sessions were an hour long, in the late afternoon, three times a week.

So this trial doesn’t show that five minutes of stretching at 10 p.m. helps. It suggests that a regular, gentle stretching habit may ease insomnia a little. Brazilian research foundations and the national science council paid for the study, and the authors reported no conflicts1.

A 2025 review of 22 trials used stretching as the yardstick

In July 2025, a team funded by China’s national science foundation published a network meta-analysis in BMJ Evidence-Based Medicine2. That’s a method for comparing many treatments at once, even ones never tested head to head, and this one pooled 22 trials with 1,348 adults who had insomnia2.

Yoga, tai chi and walking or jogging came out best2. Plain stretching wasn’t scored as a treatment at all: the authors lumped it with usual care and lifestyle advice as an “active control,” the yardstick that real treatments are measured against3.

By sleep diaries, yoga added nearly two hours of sleep a night compared with those controls, a result rated moderate in certainty3. Tai chi’s gain was about 52 minutes by diary but about 24 minutes when devices measured it3.

Most other estimates were low or very low in certainty, and only 4 of the 22 trials were judged at low risk of bias3. It also isn’t possible to hide from people whether they’re doing yoga3.

Yoga’s earlier record points the same way. A 2020 review of 19 trials in 1,832 women with sleep problems found yoga improved self-rated sleep quality, though not insomnia severity in the three trials that measured it4. It didn’t clearly help women with breast cancer or around menopause, and no serious harms were reported4. Our articles on yoga and qigong cover those practices more fully.

Put together, fuller practices like yoga and tai chi have more support for sleep than stretching alone.

A 10-minute bedside and in-bed routine

This routine is our own design, built around the muscles in the cramp trial: the calves and the hamstrings, at the back of the thigh5. It hasn’t been tested as a package. Move slowly, stop at a gentle pull rather than pain, and breathe normally throughout.

Stretching fits natural-health values well. It needs no prescription and no gear, and it asks you to listen closely to your own body. The quinine story is a reminder that the low-tech choice can also be the safer one.

  1. Bedside calf stretch, straight knee (2 minutes). Stand facing a wall or sturdy dresser with your hands on it. Step one foot back, keep that heel down and the knee straight, and lean in until you feel a pull in the calf. Hold 30 seconds, switch legs, and repeat once.
  2. Bedside calf stretch, bent knee (1 minute). Use the same position, but bend the back knee slightly so you feel the stretch lower in the calf. Hold 30 seconds per side.
  3. Seated hamstring stretch (2 minutes). Sit on the edge of the bed and straighten one leg with the heel on the floor. Keep your back long and tip forward from the hips, not by rounding your spine. Hold 30 seconds, switch legs, and repeat once.
  4. In-bed foot flexes (1 minute). Lie on your back and pull your toes toward your shins, hold for three seconds, then relax. This is the same move that helps stop a cramp in progress10.
  5. In-bed strap stretch (2 minutes). Loop a towel or belt around one foot. Keep the other leg flat or bent, and raise the looped leg until you feel the back of the thigh. Hold 30 seconds per side, twice.
  6. Rest (2 minutes). Settle into your usual sleep position, let your legs go heavy, and breathe slowly.

How to test it: Do the routine nightly for six weeks, the length of the cramp trial5. Each morning, jot down how many cramps you had and rate the worst one from 0 to 10, much like the diary the trial’s volunteers kept5.

Adjust the routine if any of these apply

Osteoporosis. Avoid bending forward with a rounded spine. That advice traces mainly to one small 1984 study of 59 women aged 49 to 60 with spinal osteoporosis and back pain. New spine fractures showed up in 89% of the women given forward-bending exercises, 67% of those given no exercise and 16% of those given back-extension exercises12. A later report described three people aged 61 to 87 with low bone mass who had pain or spine fractures they tied to yoga; all had done the plow pose12.

That’s thin evidence, but a 2013 review in the International Journal of Yoga Therapy concluded that people with osteoporosis should avoid rounding the upper back12. It suggests hinging from the hips with a straight back, as in step 3, and favoring stretches done lying on your back, as in step 512.

Hip replacement. University Hospitals in Cleveland gives patients who had the posterior (back-of-the-hip) approach a handout with three rules: don’t bend the hip past 90 degrees, don’t cross your legs or ankles, and don’t twist or pivot on the new hip, especially inward13. Steps 3 and 5 can push the hip past 90 degrees. The handout doesn’t say how long the rules last, and they’re one hospital’s rules for one surgical approach13. Ask your own surgeon or physical therapist which stretches are allowed, and when.

Pregnancy. NCCIH, the federal center for complementary health, advises avoiding poses that keep you on your back or holding still for long periods14. Do steps 4 to 6 lying on your side or seated, and check with your provider.

Arthritis. The National Institute on Aging says stretching can relieve stiffness and keep joints moving15. It also advises easing off a joint when it’s swollen or inflamed and working a different area for a day or two15.

Age 65 and older. Yoga-related sprains and strains are more common in this group, NCCIH notes, so stay within your limits14. Hold the dresser for balance during steps 1 and 2.

What the evidence shows

Claim Evidence rating What it rests on
A regular stretching habit eases insomnia Promising but early One trial of 28 adults, with a comparison group not chosen by chance1
Yoga or tai chi improves sleep Promising but early Two reviews; mostly low certainty, with no blinding possible234
Stretching right at bedtime works better than at other times Not enough evidence Neither the insomnia trial nor the 2025 review compared times of day13
Bedtime calf and hamstring stretches reduce night cramps Promising but early One positive trial of 80 people; one negative trial against fake exercises578
Stretching a muscle stops a cramp in progress Not enough evidence Widely advised and low-risk, but not well proven710
Magnesium prevents typical night cramps Evidence says no Reviews found no benefit8
Quinine for night cramps Evidence says no, or unsafe Works modestly, but FDA labeling says the risks outweigh any benefit for cramps89

The osteoporosis and hip cautions are left out of this table on purpose: they rest on one small study, case reports and hospital rules, so treat them as caution, not proof.

Questions readers ask

Should I stretch on the floor or in bed?

Either works. The cramp trial simply asked people to stretch right before sleep5. Standing calf stretches need a wall or dresser, while the strap and foot-flex steps fit comfortably in bed.

Does tonic water help leg cramps?

Tonic water contains quinine. New Zealand’s drug regulator warned that even the amount in about two cups (500 milliliters) can cause a severe drop in platelets10. Skip it as a cramp remedy.

Can stretching replace treatment for insomnia?

Not on its own. If you have trouble sleeping three or more nights a week for three months or longer, that’s chronic insomnia, and a clinician can help11. Our upcoming insomnia article covers cognitive behavioral therapy for insomnia, a drug-free treatment.

How soon should my cramps improve?

The trial measured results after six weeks5. If you see no change by then, or your symptoms match a warning sign above, get checked, since cramps can be a clue to circulation or nerve problems710.

The bottom line

Gentle stretching before bed is low-risk, free and pleasant, and it may help you sleep a little better, especially as part of a regular habit or a practice like yoga or tai chi. The research is small, though, and nobody has shown that bedtime timing matters.

Its clearest bedtime job is narrower: stretching your calves and hamstrings each night may cut down on painful leg cramps. Give it six weeks and keep a diary, skip quinine, adapt the moves for weak bones, a new hip or pregnancy, and see a clinician if your symptoms point to something more.

About this article

This article was researched using randomized trials, systematic reviews, FDA safety communications, clinical reviews in American Family Physician, and NIH and hospital guidance, all listed below. It was reviewed in October 2026. It is general education and not medical, legal or financial advice.

Sources

  1. D’Aurea CVR, Poyares D, Passos GS, et al. “Effects of resistance exercise training and stretching on chronic insomnia.” Brazilian Journal of Psychiatry, 2019;41(1):51-57 (Federal University of Minas Gerais repository). repositorio.ufmg.br
  2. BMJ Group. “Yoga, tai chi, walking and jogging may be best forms of exercise for insomnia” (news release on a network meta-analysis in BMJ Evidence-Based Medicine). July 16, 2025. bmjgroup.com
  3. BMJ Evidence-Based Medicine. “Effects of various exercise interventions in insomnia patients: a systematic review and network meta-analysis.” First published online July 2025; 2026;31(2):102. doi:10.1136/bmjebm-2024-113512. doi.org
  4. Wang WL, Chen KH, Pan YC, Yang SN, Chan YY. “The effect of yoga on sleep quality and insomnia in women with sleep problems: a systematic review and meta-analysis.” BMC Psychiatry, 2020;20:195 (abstract, Qigong Institute database). qigonginstitute.org
  5. Hallegraeff JM, van der Schans CP, de Ruiter R, de Greef MH. “Stretching before sleep reduces the frequency and severity of nocturnal leg cramps in older adults: a randomised trial.” Journal of Physiotherapy, 2012;58(1):17-22 (Hanze University record). research.hanze.nl
  6. PEDro (Physiotherapy Evidence Database). Record and quality rating for Hallegraeff et al., 2012. search.pedro.org.au
  7. Allen RE, Kirby KA. “Nocturnal Leg Cramps.” American Family Physician, 2012;86(4):350-355. aafp.org
  8. Herzberg J, Stevermer J. “Treatments for Nocturnal Leg Cramps.” American Family Physician, 2017;96(7). aafp.org
  9. U.S. Food and Drug Administration. “FDA Drug Safety Communication: New risk management plan and patient Medication Guide for Qualaquin (quinine sulfate).” FDA, July 8, 2010.
  10. bpacnz. “Nocturnal leg cramps.” Best Practice Journal, issue 49, December 2012. bpac.org.nz
  11. National Heart, Lung, and Blood Institute. “Insomnia: Diagnosis.” NHLBI, updated March 24, 2022. nhlbi.nih.gov
  12. Smith EN, Boser A. “Yoga, Vertebral Fractures, and Osteoporosis: Research and Recommendations” (reviews Sinaki M, Mikkelsen BA, Archives of Physical Medicine and Rehabilitation, 1984;65(10):593-596, and Sinaki M, Pain Practice, 2013;13(1):68-75). International Journal of Yoga Therapy, 2013;23(1):17-23. ijyt.kglmeridian.com
  13. University Hospitals (Cleveland). “Total Posterior Hip Replacement Precautions” (patient handout). uhhospitals.org
  14. National Center for Complementary and Integrative Health. “Yoga for Health” (eBook). NCCIH, updated August 2024. files.nccih.nih.gov
  15. National Institute on Aging. “Exercising With Chronic Conditions.” NIA. nia.nih.gov