Knee pain gets worse at night for a frustrating reason: you’re no longer distracted. Without the movement and mental activity of your day, your brain tunes in to pain signals it had been filtering out. On top of that, lying still for hours lets fluid accumulate around the joint, increasing stiffness and pressure. Nearly 60% of people with osteoarthritis qualify as poor sleepers, and about one in three develop clinical insomnia. The good news is that a few deliberate changes to how you position yourself, prepare your body, and set up your bed can make a real difference.
Best Sleeping Positions for Knee Pain
Your sleeping position determines how much stress your knee absorbs over six to eight hours. Small adjustments in alignment can reduce pressure on the joint capsule, ligaments, and surrounding muscles enough to let you stay asleep longer.
Side sleepers: Place a pillow between your knees. This keeps your hips, pelvis, and spine in a neutral line and prevents your top leg from pulling the knee joint inward. Without a pillow, the weight of your upper leg rotates the hip and creates a twisting force through the knee. If one knee hurts more than the other, try sleeping on the opposite side so the painful knee rests on top, cushioned by the pillow rather than compressed against the mattress.
Back sleepers: Slide a pillow under your knees. This takes tension off the kneecap and slightly bends the joint, which is a more comfortable resting position than lying completely flat. A fully extended knee stretches the hamstrings and calf muscles, which can increase pulling forces around an already irritated joint. If you also have swelling, stack enough pillows to raise your knee above heart level, which helps fluid drain away from the joint.
Stomach sleepers: This is the toughest position for knee pain. Lying face down forces your kneecap directly into the mattress and hyperextends the joint. If you can’t switch positions, placing a thin pillow under your shins lifts the kneecap slightly off the surface. Transitioning to side sleeping with a knee pillow is worth the effort if you can manage it.
Choosing the Right Knee Pillow
Not all pillows work equally well between or under your knees. A regular bed pillow compresses flat within an hour, and once it does, you lose the alignment benefit entirely. Dedicated knee pillows are designed to hold their shape under the weight of your legs all night.
Firm, high-density memory foam is the most commonly recommended fill. It cushions without sinking, so your legs stay in position even as you shift during sleep. Several top-rated options use solid memory foam cores specifically because the dense composition conforms to the shape of your leg while providing enough pushback to maintain spinal alignment. If a firm pillow feels uncomfortable against sensitive knees, look for a medium-firm option or one with an adjustable design that lets you remove or add a foam insert to fine-tune the thickness.
Contoured or hourglass-shaped pillows are worth considering. The tapered middle section cradles between your knees more securely than a rectangular block, which tends to slide out of place during the night.
Ice, Heat, or Both Before Bed
Temperature therapy applied 20 to 30 minutes before you get into bed can reduce pain enough to help you fall asleep faster. The key is knowing which one to use.
Ice works best when your knee is swollen, warm to the touch, or flaring after an active day. Apply a cold pack wrapped in a thin towel for 10 to 15 minutes. Don’t go past 20 minutes, as prolonged cold can damage skin and underlying tissue. Elevate your knee during icing to maximize the reduction in swelling.
Heat is better for stiff, achy knees without noticeable swelling. A warm towel, microwavable heat wrap, or warm bath loosens tight muscles around the joint and increases blood flow. Keep heat sessions under 20 minutes. If you’re using moist heat like a bath or warm compress, aim for a temperature between 92 and 100 degrees Fahrenheit, which is warm enough to relax tissue without risking a burn.
Some people benefit from alternating: ice first to calm inflammation, then gentle warmth to ease stiffness. Experiment over a few nights to see what your knee responds to best.
Bedtime Stretches That Reduce Stiffness
Gentle stretching before bed signals your muscles to relax and can reduce the stiffness that builds during the first few hours of sleep. These should feel like a mild pull, never sharp pain.
Single knee to chest: Lie on your back with both legs extended. Bring one knee up and hold behind it with both hands, gently pulling it toward your chest. Hold for 30 seconds, repeat three times, then switch legs. If your lower back feels uncomfortable, bend the opposite leg to support your pelvis. This opens up the hip and takes tension off structures that connect to the knee.
Supine hamstring stretch: Still on your back, lift one leg straight up and grasp the back of your calf with both hands. Hold for 30 seconds. Tight hamstrings are one of the most common contributors to knee pain because they pull on the joint from behind, increasing compression. Repeat five to ten times on each side.
Both stretches can be done in bed, which makes them easy to turn into a nightly habit. Spend five minutes total and you’ll likely notice less middle-of-the-night stiffness within a week or two.
Mattress and Sleep Setup Tips
Your mattress matters more than you might expect. A surface that’s too soft lets your body sink unevenly, pulling your knee out of alignment. A surface that’s too firm creates pressure points on the side of the knee and hip. Medium-firm mattresses tend to offer the best balance of cushioning and support for joint pain.
If replacing your mattress isn’t realistic, a mattress topper (two to three inches of memory foam or latex) can improve things significantly. The goal is enough give to cushion bony prominences while keeping your spine and legs level.
Room temperature also plays a role. Cold air stiffens joints. Keeping your bedroom comfortably warm, or at least keeping your legs under a blanket even in summer, helps maintain circulation to the knee overnight.
What Makes Knee Pain Worse at Night
Several common habits amplify nighttime knee pain without people realizing it. Heavy exercise late in the evening can trigger inflammatory responses that peak two to three hours later, right when you’re trying to fall asleep. If you exercise in the evening, shift intense leg work to earlier in the day and keep nighttime activity gentle.
Sitting with your knee deeply bent for long periods before bed, like in a low couch or recliner, compresses the joint and can cause it to stiffen by the time you lie down. Try to straighten and gently move your knee every 20 to 30 minutes during the evening hours.
Carrying extra body weight increases the load on your knees even while lying down, because the surrounding muscles stay under tension to stabilize a joint that bears more force during the day. Even modest weight loss, in the range of 10 to 15 pounds, can meaningfully reduce nighttime knee discomfort.
Signs Your Knee Pain Needs Medical Attention
Most nighttime knee pain responds to the strategies above, but certain symptoms point to something that needs professional evaluation. Contact a doctor if your knee can’t bear weight, feels like it gives out or locks in place, or shows obvious deformity. A fever combined with redness, swelling, and pain in the knee can signal an infection in the joint, which requires urgent treatment. Severe pain following an injury, inability to fully straighten or bend the knee, or rapid swelling that appears within hours are all reasons to get imaging and an exam rather than managing things at home.

