"Coffee Doesn't Affect My Sleep" — Except It Probably Does
Almost everyone who drinks coffee has a version of the same line: "I can drink an espresso after dinner and sleep like a baby." Some people genuinely can. Most people who say it are conflating "I fell asleep" with "I slept well" — which are not the same thing, and the polysomnography data makes that clear.
Caffeine's whole trick is that it doesn't actually give you energy. It blocks adenosine, the molecule that builds up in your brain across the day and creates the pressure to sleep. Adenosine is still there; caffeine just squats on the receptors so your brain can't read the signal. When the caffeine finally clears, all that backed-up adenosine hits at once — which is part of why the afternoon crash exists, and part of why coffee taken too late doesn't just delay sleep, it flattens its quality.
How Long Does Caffeine Stay in Your System?
The short version: longer than most people think.
The FDA puts the half-life of caffeine at roughly 4 to 6 hours in a healthy adult, but the Sleep Foundation notes the real range across the population is closer to 2 to 12 hours, depending on genetics, pregnancy, smoking status and other drugs you take. Half-life is the time it takes your body to clear half of what you consumed — so if you had a 200 mg coffee at 3pm and your half-life is 6 hours, you still have 100 mg circulating at 9pm and 50 mg at 3am.
That's the part that catches people out. "I don't feel wired" is not the same as "the drug is out of my system."
Genetics does most of the heavy lifting here. A common variant of the CYP1A2 gene, which encodes the liver enzyme that metabolises caffeine, produces slower clearance in roughly half the population. Nicotine roughly halves caffeine's half-life; pregnancy roughly doubles it. Which means the person telling you they "sleep fine after coffee" may genuinely metabolise it in three hours, while you're carrying the same dose into your REM cycles.
What the 2024 Trial Actually Found
The most useful recent data comes from a randomised, placebo-controlled crossover trial published in Sleep in 2024, which tested caffeine at 100 mg (roughly one instant coffee) and 400 mg (roughly three strong brewed cups, or the daily upper limit most health authorities suggest) at 4, 8, and 12 hours before bed.
| Dose & timing | Effect on that night's sleep |
|---|---|
| 100 mg, any timing (even 4h before bed) | No significant disruption |
| 400 mg, 4 hours before bed | ~50 minutes less total sleep; ~14 minutes longer to fall asleep |
| 400 mg, 8 hours before bed | ~29 minutes less total sleep (not statistically significant) |
| 400 mg, 12 hours before bed | ~15 minutes longer to reach persistent sleep; deep sleep still measurably reduced |
Read that last row again. Even twelve hours out, a 400 mg dose still measurably changed sleep architecture — pushing time in light (N1/N2) sleep up by 5–6%, and cutting deep, slow-wave (N3) sleep by 15–30 minutes. Slow-wave sleep is the stage most tightly linked to feeling physically restored the next day. You can fall asleep and still lose it.
So What's a Sensible Cut-Off?
Two rough rules, calibrated to dose, cover most people:
- Standard single coffee (roughly 80–120 mg): at least 8 hours before bed. That's the general Sleep Foundation guideline, and it lines up with the trial finding that 100 mg didn't reliably disrupt sleep even at 4 hours out — an 8-hour buffer gives most slow metabolisers a margin.
- Pre-workout, double espresso, or a second coffee after lunch (200–400 mg): treat 12 hours before bed as the real cut-off if you care about deep sleep, not just falling asleep. For a 10:30pm bedtime, that's 10:30am.
If you bedtime is 11pm and your last coffee is 4pm, you are inside the disruption window for anything over about 150 mg. That doesn't mean you'll lie awake staring at the ceiling. It means the sleep you get is likely a bit lighter than it would have been otherwise, and repeated night after night, that adds up.
The Singapore-Specific Bit
Iced lattes, kopi and 3-in-1s aren't dosed the same. A local kopi O kosong pulls roughly 60–100 mg per cup depending on the shop; a Starbucks grande brewed coffee is closer to 300 mg; a Red Bull can is around 80 mg; a pre-workout scoop is often 200–400 mg in a single serving. Cold brew, popular in the afternoon heat here, is typically stronger than hot drip because of the longer extraction — a 500ml bottle can push 200 mg easily.
If your ritual is a 3pm cold brew to get through the afternoon slump, that is exactly the dose × timing combination the trial flagged. It's not a moral failure — it's just an unusually costly caffeine hit, and swapping it for something lower-dose (a single espresso, a matcha, or actually a ten-minute walk) is the cheapest sleep upgrade available.
How to Actually Test This on Yourself
The honest answer is: track it for a week. Note the time and rough dose of your last caffeine each day, and note whether you felt genuinely rested the next morning — not whether you fell asleep quickly, but whether you woke up wanting more sleep. Most people who think they're immune find a pattern inside seven days.
If you use a wearable that estimates deep-sleep minutes, the same experiment gets easier: hold everything else constant and shift only your caffeine cut-off earlier by two hours for a week. The change is usually visible.
You don't have to quit coffee. You just have to stop pretending the 4pm one is free.
You don't have to quit caffeine to sleep better — you just have to move your last dose earlier. For most people, shifting the cut-off from 4pm to noon changes deep-sleep quality more than any supplement will.