How to Sleep at Night With Anxiety: What Actually Works

Anxiety and sleep have a frustrating circular relationship: worry keeps you awake, and poor sleep makes anxiety worse the next day. Breaking that cycle is possible, though, with a combination of physical techniques, environmental changes, and shifts in how you relate to your racing thoughts at bedtime. Most of these strategies work within days or weeks, not months.

Why Anxiety Disrupts Sleep

When you feel anxious, your body’s stress response floods your system with hormones that raise your heart rate, tense your muscles, and sharpen your alertness. That’s useful during the day if you need to react to something, but it’s the opposite of what your body needs to fall asleep. Sleep requires your nervous system to shift into its calm, restorative mode. Anxiety essentially locks the door to that shift.

The mental side compounds the physical one. Lying in a dark, quiet room with nothing to distract you gives anxious thoughts free rein. You might replay the day, rehearse tomorrow’s problems, or worry about the fact that you’re not sleeping yet. That last one, called “sleep anxiety,” can become its own self-sustaining problem where the bed itself starts to feel like a stressful place.

Use Your Breath to Calm Your Nervous System

The fastest tool you have is controlled breathing, because it directly activates the branch of your nervous system responsible for calming you down (the parasympathetic system). One well-studied pattern is called 4-7-8 breathing: inhale quietly through your nose for 4 seconds, hold your breath for 7 seconds, then exhale slowly through your mouth for 8 seconds. Repeat for three to four cycles.

The long exhale is the key. It lowers your heart rate and blood pressure, putting your body into the physical state it needs to initiate sleep. This technique gets more effective with practice. If you do it consistently for a few weeks, your body learns to drop into that relaxed state faster each time. Try it before bed as a nightly ritual rather than only pulling it out during a panic.

Progressive Muscle Relaxation

Anxiety stores itself in your body as tension you may not even notice until you’re lying still. Progressive muscle relaxation (PMR) works by systematically tensing and then releasing each muscle group, which makes it easier to recognize and let go of that held tension. Harvard Health recommends starting at your feet: curl your toes and arch your feet, hold briefly, then release and let them sink heavy into the mattress.

From there, move slowly upward through your calves, thighs, buttocks, lower back, abdomen, upper back, shoulders, arms, hands, neck, jaw, and forehead. Breathe out with a long sigh each time you release. The whole sequence takes about 10 to 15 minutes. Most people find that by the time they reach their shoulders, the urge to keep worrying has faded because their attention has been occupied by physical sensation instead of thought loops.

Manage Racing Thoughts Before Bed

One reason anxious thoughts explode at bedtime is that it’s the first moment all day your brain has space to process unresolved concerns. You can short-circuit this by giving your brain that processing time earlier. Set aside 15 to 20 minutes in the evening, well before you get into bed, to write down everything that’s on your mind. List tomorrow’s tasks, note worries, jot down unfinished problems. The goal isn’t to solve them. It’s to externalize them so your brain doesn’t feel compelled to keep cycling through them once your head hits the pillow.

If anxious thoughts still show up in bed, try not to fight them directly. Thought suppression (“stop thinking about that”) tends to backfire and make thoughts more persistent. Instead, notice the thought, label it (“that’s a worry about work”), and redirect your attention to your breath or your body scan. You’re not arguing with the thought. You’re just choosing where to put your focus.

Set Up Your Bedroom for Sleep

Your sleep environment matters more than you might expect, especially when anxiety is involved. Temperature is a big one: your core body temperature needs to drop slightly to initiate sleep, and a warm room fights that process. Keep your bedroom between 60 and 67°F (15 to 19°C). That range also helps stabilize the deepest stages of sleep throughout the night.

A weighted blanket can help with nighttime anxiety. The gentle, even pressure mimics the sensation of being held, which promotes a sense of safety and calm. The general guideline is to choose one that weighs about 10% of your body weight, though anywhere from 5% to 12% works depending on personal preference. If you weigh 150 pounds, start with a 15-pound blanket.

Keep the room dark and quiet. If complete silence makes your thoughts louder, a white noise machine or fan gives your brain something neutral to latch onto instead of scanning for threats, which is what an anxious brain tends to do in silence.

Cut Screen Time Before Bed

Scrolling your phone in bed is one of the worst things you can do for anxious sleep, and the problem goes beyond content that stresses you out. The blue light from screens directly suppresses your body’s production of melatonin, the hormone that signals it’s time to sleep. A two-hour exposure to an LED screen can cut melatonin levels by 55% and delay the onset of sleepiness by about an hour and a half compared to reading a printed book under low light.

Put your phone in another room at least an hour before bed if you can. If that feels impossible, start with 30 minutes and use night mode to reduce blue light output. Replace the scrolling habit with something that occupies your hands and eyes without stimulating anxiety: a physical book, a crossword puzzle, or gentle stretching.

CBT-I: The Most Effective Long-Term Fix

If anxiety-driven insomnia has become a regular pattern rather than an occasional bad night, Cognitive Behavioral Therapy for Insomnia (CBT-I) is the gold standard treatment. It works for 7 to 8 out of 10 people, and it addresses both the thought patterns and the behavioral habits that keep insomnia going. It’s particularly effective when anxiety is part of the picture, because it reduces anxiety symptoms alongside sleep problems.

CBT-I is a short-term therapy, typically four to eight sessions spread over weekly or biweekly appointments. Each session runs 30 to 60 minutes. You’ll learn techniques like stimulus control (retraining your brain to associate the bed with sleep rather than worry), sleep restriction (temporarily limiting time in bed to build stronger sleep drive), and cognitive restructuring (challenging the catastrophic thoughts about sleep that fuel the cycle). Most people see meaningful improvement within six to eight weeks. You can access CBT-I through a therapist or through clinically validated apps if in-person therapy isn’t accessible.

Daytime Habits That Affect Nighttime Anxiety

What you do during the day shapes how your nervous system behaves at night. Regular physical activity, even a 30-minute walk, reduces baseline anxiety levels and makes it easier for your body to transition into sleep. The timing matters: vigorous exercise within two to three hours of bedtime can leave you too activated to sleep, so aim for morning or afternoon workouts.

Caffeine is another common culprit. It has a half-life of about five to six hours, meaning half the caffeine from your 2 p.m. coffee is still circulating at 7 or 8 p.m. If you’re prone to nighttime anxiety, try cutting off caffeine by noon for two weeks and see if your evenings feel different.

Magnesium plays a role in nervous system regulation, and many people don’t get enough through diet alone. The recommended daily intake is 310 to 320 mg for adult women and 400 to 420 mg for adult men. Foods like dark leafy greens, nuts, seeds, and legumes are good sources. If you’re considering a supplement, magnesium glycinate is a commonly recommended form because it’s well absorbed and less likely to cause digestive issues than other types.

Build a Consistent Wind-Down Routine

An anxious brain craves predictability. A consistent pre-sleep routine, done in the same order each night, signals to your nervous system that sleep is coming. This doesn’t need to be elaborate. It might look like: screens off, brew herbal tea, write in a worry journal for 10 minutes, do a progressive muscle relaxation sequence, then 4-7-8 breathing in bed with the lights off. The specific activities matter less than the consistency. Over a few weeks, the routine itself becomes a cue that tells your body to start winding down, making the transition from anxious alertness to sleep progressively smoother each night.