CaffeineTime

Caffeine & sleep

Waking up at night after caffeine: why it happens

Updated 2026-10-03 · Checked against the sources below by Oleksii Y. · 8 min read

Yes, caffeine can wake you in the night even when you fall asleep easily. It makes sleep lighter and more broken: in a 2025 trial, 400 mg taken 4 or 8 hours before bed added about 26 to 29 minutes of time awake after falling asleep. Because caffeine’s half-life is about 2 to 8 hours, an afternoon coffee can still be in your system at 3 a.m. The calculator below shows how much might be left.

How much will be left at bedtime?

Left at 11:00 PM (8 h later), average metabolism

≈ 33 mg

Range 16–50 mg (fast to slow metabolism)

To be at 50 mg or less by bedtime, have 100 mg by 5:15 PM (average) or 2:15 PM (slow metabolism).

What sleep studies found near this dose

  • Gardiner et al. 2025 (randomized trial): In 23 healthy young men, 100 mg taken 12, 8 or 4 hours before bed had no significant effect on measured or self-rated sleep.
  • Gardiner et al. 2023 (meta-analysis): To avoid losing sleep time, the authors suggest a coffee (107 mg per 250 ml) at least 8.8 hours before bed.

Estimate from a simple model: half-life of 3, 5 or 8 hours, 50 mg bedtime target. How we calculate

Key takeaways

  • Caffeine shifts sleep toward lighter stages and adds time awake after you first fall asleep, about 12 minutes on average in a 2023 meta-analysis.
  • Caffeine fades gradually, so an afternoon dose can leave a measurable amount in your body in the small hours, especially if you clear it slowly.
  • In one small study, 200 mg taken at 7 a.m. still reduced total sleep that night.
  • People often under-report the extra waking: in a 2025 trial it showed up on sleep recordings but not in self-ratings.
  • Waking with a pounding heart plus chest pain, breathlessness or faintness needs emergency care.

How caffeine breaks up sleep in the middle of the night

Adenosine is widely accepted as one of the brain’s natural sleep-regulating substances, and caffeine works mainly by blocking the receptors it acts on. That does more than delay sleep. In a 2023 meta-analysis of 24 studies, caffeine added about 12 minutes of wake time after sleep onset, increased the lightest stage of sleep (N1) by about 6 minutes and cut deep sleep by about 11 minutes.

In a 2025 trial in 23 healthy young men, 400 mg taken within 8 hours of bed fragmented sleep, and at 4 or 8 hours before bed it added about 26 to 29 minutes of time awake after falling asleep. The men’s own estimates of time awake did not change significantly, so you may be awake more than you remember.

An earlier systematic review of trials and population studies found the same pattern: caffeine typically increased the lightest stage of sleep, time awake and brief arousals during the night.

How much caffeine is left in your body at 3 a.m.

EFSA puts caffeine’s average half-life in healthy adults at about 4 hours, with a range of 2 to 8 hours, and one study of 16 healthy men found 2.3 to 9.9 hours. The table uses EFSA’s average and the top of its range to show what that means for a single 100 mg coffee by 3 a.m.

These are arithmetic illustrations: they ignore absorption time, and real bodies vary. No study cited here tested how much caffeine it takes at 3 a.m. to wake someone up, but the numbers show why "I had it hours ago" does not mean it is gone. A real measurement agrees: in a small lab study, 200 mg taken at about 7 a.m. was still detectable in saliva at 11 p.m., at roughly a sixth of its peak.

To run the numbers for your own drink and bedtime, use the calculator above or see how long caffeine lasts.

Caffeine left at 3 a.m. from a 100 mg coffee (simple halving arithmetic)
Coffee atHours to 3 a.m.Left if half-life is 4 hLeft if half-life is 8 h
8 a.m.19about 4 mgabout 19 mg
Noon15about 7 mgabout 27 mg
3 p.m.12about 13 mgabout 35 mg
6 p.m.9about 21 mgabout 46 mg

Can morning coffee cause waking up at night?

It can contribute. In a 1995 lab study of nine healthy men, 200 mg of caffeine taken at about 7 a.m. reduced total sleep time and sleep efficiency that night compared with placebo. In the 2025 trial, 400 mg taken 12 hours before bed still cut deep sleep by about 21 minutes.

Other evidence is gentler. In the same 2025 trial, 100 mg taken 12, 8 or 4 hours before bed made no significant difference to measured or self-rated sleep. And in a 10-day study with an unusual sleep schedule, men taking 150 mg three times during the day showed no significant change in total sleep or sleep stages, though REM sleep started later and they felt more tired on waking.

On this evidence, a single modest morning coffee seems unlikely to explain night waking on its own. A large morning dose, or several cups spread through the day, can reach into the night, especially if you clear caffeine slowly.

Who is most likely to wake at night after caffeine

Some groups are more likely to find caffeine still active, or their sleep more sensitive to it, in the early hours:

  • Older and middle-aged adults: a systematic review found older adults’ sleep may be more sensitive to caffeine, and a lab study found 400 mg disrupted sleep more in middle-aged than in young adults.
  • People taking estrogen-containing birth-control pills: half-life averaged about 7.9 hours vs 5.4 hours in non-users in one small study.
  • Pregnant people: half-life averaged 8.3 hours (range 3 to 16) in one study, against 3.4 hours in non-pregnant adults.
  • People on certain medicines: fluvoxamine raised caffeine’s half-life from about 5 to 31 hours and ciprofloxacin from about 4.5 to 9.7 hours in single studies. Ask your doctor or pharmacist about your medicines.
  • People who recently quit smoking: caffeine clearance fell by about 36% within days of stopping in heavy smokers, so the usual coffee can last longer.
  • Anyone drinking large coffee-shop sizes: lab tests found 58 to 259 mg per serving.

When night waking after coffee comes with a racing heart

The FDA lists a faster heart rate and palpitations among the signs of too much caffeine, and the NHS lists caffeine as a common trigger for palpitations. Get emergency help (your local emergency number) if palpitations come with chest pain, shortness of breath, or feeling faint or fainting.

If you wake with a pounding heart regularly, see a doctor even if you suspect caffeine; do not assume it is the coffee. More on this in caffeine and a racing heart. Waking in panic, with or without caffeine, is covered by calmness.today.

Getting back to sleep after a caffeine wake-up at 3 a.m.

These are practical habits, not remedies tested against caffeine. The aim is to avoid adding more alertness while the remaining caffeine keeps falling.

  • Keep the lights low and leave your phone alone, including for checking the time.
  • Skip any caffeine, including tea or a cola from the fridge.
  • If you have been awake for what feels like a long time, get up and do something quiet in dim light until you feel sleepy, then go back to bed.
  • Don’t do the math on how much sleep is left; that is a job for tomorrow’s planning, not tonight.

Changing your caffeine timing to stop waking at night

The fix happens the next day: move your last caffeine earlier and make afternoon doses smaller. A 2023 meta-analysis estimated that a standard coffee (107 mg) should be had at least 8.8 hours before bed to avoid losing sleep time, and the authors of the 2025 trial advise keeping 400 mg at least 12 hours away from bedtime.

The caffeine cutoff calculator turns your bedtime and drink into a latest time, and the caffeine calculator plans a whole day. Keep the change for a week or two. If you still wake most nights with little or no caffeine after midday, caffeine probably is not the main cause; goodsleep.today covers sleep problems more broadly, and regular night waking that affects your days is worth raising with a doctor.

Common questions

Why does caffeine wake me up at 3 a.m. but not stop me falling asleep?

Caffeine’s effects are not limited to the start of the night. Studies show it adds light sleep and extra time awake after you first fall asleep. If you are tired at bedtime you may drop off quickly, then wake later as sleep turns lighter while some caffeine is still in your system.

Can caffeine keep you awake 12 hours later?

It can still affect sleep that long after. In a 2025 trial, 400 mg taken 12 hours before bed reduced deep sleep by about 21 minutes, and in a small 1995 study 200 mg taken at 7 a.m. reduced total sleep that night. In the same 2025 trial, 100 mg taken 12 hours before bed showed no measurable effect.

Does caffeine make you wake up at night to pee?

Probably not at normal amounts. A review found caffeine in standard servings of tea, coffee and soft drinks does not appear to act as a diuretic. Large doses, at least about 250 to 300 mg, can briefly increase urine output in people who have not had caffeine for a while. The fluid in a late drink still counts, of course.

Can decaf in the evening cause night waking?

Decaf is a far smaller dose: the FDA says an 8 oz cup typically has 2 to 15 mg, against 113 to 247 mg in 12 oz of regular brewed coffee. None of the studies cited here tested decaf and night waking, but it gives your sleep much less caffeine to deal with than regular coffee.

How early should I stop caffeine if I keep waking up at night?

It depends on dose and on how fast you clear caffeine. One meta-analysis suggests a standard 107 mg coffee at least 8.8 hours before bed, and trial authors advise keeping 400 mg at least 12 hours away. Try an earlier cutoff for two weeks and see whether night waking changes.

General information, not medical advice

If you feel unwell after caffeine — for example chest pain, a fast or irregular heartbeat that does not settle, fainting, confusion or trouble breathing — get urgent medical help. If you are pregnant or breastfeeding, under 18, take medication, or have a heart, liver or anxiety condition, high blood pressure or a sleep disorder, ask a doctor or pharmacist what amount is right for you.

Sources

  1. Gardiner C, Weakley J, Burke LM, et al. (2023). The effect of caffeine on subsequent sleep: A systematic review and meta-analysis. Sleep Medicine Reviews, 69, 101764. doi:10.1016/j.smrv.2023.101764 ↗
  2. Gardiner CL, Weakley J, Burke LM, et al. (2025). Dose and timing effects of caffeine on subsequent sleep: a randomized clinical crossover trial. Sleep, 48(4), zsae230. doi:10.1093/sleep/zsae230 ↗
  3. Reichert CF, Deboer T, Landolt HP. (2022). Adenosine, caffeine, and sleep-wake regulation: state of the science and perspectives. Journal of Sleep Research, 31(4), e13597. PMID 35575450 ↗
  4. McLellan TM, Caldwell JA, Lieberman HR. (2016). A review of caffeine's effects on cognitive, physical and occupational performance. Neuroscience & Biobehavioral Reviews, 71, 294–312. PMID 27612937 ↗
  5. European Food Safety Authority (2015). EFSA explains risk assessment: Caffeine. European Food Safety Authority (doi:10.2805/618813). efsa.europa.eu (PDF) ↗
  6. Blanchard J, Sawers SJ. (1983). Comparative pharmacokinetics of caffeine in young and elderly men. Journal of Pharmacokinetics and Biopharmaceutics, 11(2), 109–126. PMID 6886969 ↗
  7. Landolt HP, Werth E, Borbély AA, et al. (1995). Caffeine intake (200 mg) in the morning affects human sleep and EEG power spectra at night. Brain Research, 675(1–2), 67–74. PMID 7796154 ↗
  8. Weibel J, Lin YS, Landolt HP, et al. (2021). Regular Caffeine Intake Delays REM Sleep Promotion and Attenuates Sleep Quality in Healthy Men. Journal of Biological Rhythms, 36(4), 384–394. PMID 34024173 ↗
  9. Clark I, Landolt HP. (2017). Coffee, caffeine, and sleep: A systematic review of epidemiological studies and randomized controlled trials. Sleep Medicine Reviews, 31, 70–78. PMID 26899133 ↗
  10. Robillard R, Bouchard M, Cartier A, et al. (2015). Sleep is more sensitive to high doses of caffeine in the middle years of life. Journal of Psychopharmacology, 29(6), 688–697. PMID 25759402 ↗
  11. Abernethy DR, Todd EL. (1985). Impairment of caffeine clearance by chronic use of low-dose oestrogen-containing oral contraceptives. European Journal of Clinical Pharmacology, 28(4), 425–428. PMID 4029248 ↗
  12. Knutti R, Rothweiler H, Schlatter C. (1981). Effect of pregnancy on the pharmacokinetics of caffeine. European Journal of Clinical Pharmacology, 21(2), 121–126. PMID 7341280 ↗
  13. Jeppesen U, Loft S, Poulsen HE, et al. (1996). A fluvoxamine-caffeine interaction study. Pharmacogenetics, 6(3), 213–222. PMID 8807660 ↗
  14. Mahr G, Sörgel F, Granneman GR, et al. (1992). Effects of temafloxacin and ciprofloxacin on the pharmacokinetics of caffeine. Clinical Pharmacokinetics, 22(Suppl 1), 90–97. PMID 1319876 ↗
  15. Faber MS, Fuhr U. (2004). Time response of cytochrome P450 1A2 activity on cessation of heavy smoking. Clinical Pharmacology & Therapeutics, 76(2), 178–184. PMID 15289794 ↗
  16. McCusker RR, Goldberger BA, Cone EJ. (2003). Caffeine content of specialty coffees. Journal of Analytical Toxicology, 27(7), 520–522. PMID 14607010 ↗
  17. Maughan RJ, Griffin J. (2003). Caffeine ingestion and fluid balance: a review. Journal of Human Nutrition and Dietetics, 16(6), 411–420. PMID 19774754 ↗
  18. U.S. Food and Drug Administration (2024). Spilling the Beans: How Much Caffeine is Too Much? FDA Consumer Updates. fda.gov ↗
  19. NHS. Heart palpitations. NHS. nhs.uk ↗

An app for better sleep is on the way

We’re working on a mobile app to help you sleep better. It isn’t out yet. Leave your email and we’ll let you know when it launches.