If you’re lying in bed unable to sleep, the single most effective thing you can do is get up. Staying in bed while awake trains your brain to associate the bed with frustration, not rest. What follows are specific, evidence-backed techniques you can use tonight and habits that prevent the problem from repeating.
Get Out of Bed After 15 Minutes
This is the cornerstone of what sleep specialists call stimulus control therapy, and it’s one of the most well-supported strategies for insomnia. The rule is simple: if you haven’t fallen asleep within roughly 15 minutes, leave the bedroom. You don’t need to watch the clock obsessively. If it feels like it’s been a while and you’re clearly still awake, that’s your signal.
Once you’re up, do something quiet and enjoyable in another room. Reading with a soft light works well. Watching TV from a distance is acceptable. Avoid your phone, laptop, or tablet. The light from a screen held close to your face is brighter than most people realize, and the content tends to be mentally stimulating rather than calming. Stay out of bed for at least 15 minutes, or until you notice genuine drowsiness returning. Then go back to bed. If sleep still doesn’t come, repeat the process. It can feel tedious the first few nights, but over time it rebuilds the mental link between your bed and falling asleep.
Slow Your Breathing Down
When you can’t sleep, your nervous system is often stuck in alert mode. Controlled breathing is one of the fastest ways to shift it toward relaxation. The 4-7-8 technique is a good place to start: breathe in through your nose for 4 counts, hold for 7 counts, then exhale slowly through your mouth for 8 counts. The extended exhale is what does the work, activating the part of your nervous system responsible for calming you down.
You don’t need to do this perfectly. If holding for 7 counts feels uncomfortable, shorten the whole cycle proportionally. The key is making the exhale longer than the inhale. Repeat for four to six cycles. With regular practice, your body learns to respond to this pattern more quickly.
Give Your Mind Something Boring to Do
Most people who can’t sleep are stuck in a loop of worry, planning, or replaying the day. You can’t force your brain to stop thinking, but you can redirect it toward something so dull that sleep takes over. Two techniques work especially well.
Cognitive Shuffling
Pick a random letter, then visualize objects that start with it. If you choose “B,” you might picture a banana, then a boat, then a balloon. Spend a few seconds on each image, making it vivid. Imagine the yellow of the banana peel, the way a boat rocks on water. This randomness mimics the scattered thought patterns your brain naturally produces as it drifts off, and it makes it nearly impossible to maintain a coherent worry thread. If you run out of words for one letter, move to the next. Most people don’t make it very far before falling asleep.
Paradoxical Intention
This one sounds counterintuitive: instead of trying to fall asleep, try to stay awake. Lie comfortably with the lights off, but keep your eyes open. Don’t do anything stimulating. Just gently resist the urge to close your eyes. When your eyelids feel heavy, tell yourself “just a couple more minutes.” By removing the pressure to fall asleep, you eliminate the performance anxiety that often keeps people awake. Sleep researchers at the University of Pennsylvania include this as a formal treatment for insomnia. The goal isn’t to force wakefulness. It’s to stop fighting, which lets sleep arrive on its own.
Relax Your Body Muscle by Muscle
Progressive muscle relaxation is a technique recommended by Harvard Health for sleep specifically. Starting at your feet, curl your toes and arch your feet, hold the tension briefly, then release completely and let your feet sink into the mattress. Work your way up: calves, thighs, buttocks, lower back, abdomen, upper back, shoulders, arms, hands, neck, jaw, forehead. Breathe softly throughout.
The point isn’t the tensing. It’s the contrast. Your muscles relax more deeply after being deliberately tightened, and the slow progression up your body gives your mind a single, repetitive task to follow. Many people fall asleep before reaching their shoulders.
Check Your Bedroom Temperature
Your body needs to cool down slightly to fall asleep, and a warm room works against that process. The National Sleep Foundation recommends keeping your bedroom between 60 and 67 degrees Fahrenheit. Some sleep researchers suggest the sweet spot is even narrower, around 60 to 65 degrees. If you don’t have air conditioning or a thermostat you can fine-tune, a fan pointed near (not directly at) you, lighter bedding, or wearing less to bed all help.
A room that feels comfortable while you’re reading on the couch may still be too warm for sleep. Your body temperature drops during the night, so what feels slightly cool when you first get into bed is often just right an hour later.
Rethink Your Afternoon Caffeine
Caffeine has a half-life of four to six hours. That means if you drink a cup of coffee at 4 p.m., half the caffeine is still circulating in your body at 10 p.m. Even if you feel like you can fall asleep fine, research shows caffeine consumed as early as six hours before bedtime can reduce sleep quality without you noticing. The general recommendation is to cut off caffeine by early to mid-afternoon, around 2 or 3 p.m. for someone with a standard evening bedtime. This includes tea, energy drinks, and chocolate, not just coffee.
Magnesium as a Sleep Supplement
If you’re looking for a supplement to try, magnesium is the one with the most reasonable evidence behind it. The Cleveland Clinic recommends 200 milligrams taken about 30 minutes before bed. The form matters: magnesium glycinate and magnesium citrate are the types most likely to help with sleep. Magnesium oxide, which is commonly sold, is primarily a stool softener and won’t do much for insomnia.
Magnesium isn’t a sedative. It supports muscle relaxation and nervous system regulation, which can make it easier to wind down. It works best as one piece of a broader routine, not as a standalone fix.
When Sleeplessness Becomes a Pattern
A bad night here and there is normal. But if you’re having trouble falling or staying asleep at least three nights per week, and it’s been going on for three months or more, that meets the clinical definition of chronic insomnia. At that point, the most effective treatment isn’t medication. It’s a structured program called cognitive behavioral therapy for insomnia (CBT-I), which combines many of the techniques above into a personalized plan. CBT-I is typically delivered over four to eight sessions and has strong long-term results, often outperforming sleep medications because it addresses the underlying patterns rather than masking symptoms.
If tonight is just a rough night, the techniques above will likely be enough. Start with the 15-minute rule, add a breathing or relaxation exercise, and resist the urge to scroll your phone. Sleep usually comes faster when you stop chasing it.