OVERLOAD
Recovery · Sleep

How late can you drink caffeine before it wrecks your sleep?

Grade · Moderate
The short answer

There's no single safe hour — it depends on the dose and how fast you personally clear caffeine. As a rule of thumb, treat six hours before bed as a bare minimum, not a target, and push it earlier if you drink more than a small coffee or know caffeine hits you hard.

Caffeine doesn’t clear on a clean schedule. Half-life averages around five hours but ranges from two to eight-plus depending on the person, and a quarter of a dose can still be circulating ten to twelve hours later. That’s the mechanism behind “cut off caffeine by early afternoon” advice — an evening coffee can still be active at 2 a.m. even if you felt fine all night.

The more useful distinction is what “wrecks sleep” means. Most people judge caffeine by how long it takes to fall asleep; sleep labs measure something stricter — total sleep time, efficiency, wake-ups, and deep slow-wave sleep, via polysomnography instead of a stopwatch. A 2023 meta-analysis of 24 studies found caffeine cut total sleep time by about 45 minutes and efficiency by roughly 7 points, shifting sleep toward lighter stages. You can fall asleep on schedule and still sleep measurably worse.

Dose moves the deadline more than the clock does

A 2025 crossover trial giving 100 or 400 mg of caffeine 12, 8, or 4 hours before bed found the small dose did essentially nothing at any timing. The large dose fragmented sleep and delayed onset even 8 hours out, cutting deep sleep and perceived quality by roughly a third at 4 hours. An older, widely cited trial found 400 mg taken 0, 3, or 6 hours before bed all cost 40-60 minutes of sleep — the basis for the standard six-hour rule. The newer data suggest that’s a floor, not a guarantee, once the dose is large.

Your gene sets a cutoff too

CYP1A2, the enzyme behind roughly 95% of caffeine clearance, has a common variant splitting people into faster and slower metabolizers — slow metabolizers carry an effective dose deeper into the night on the same cup. That’s a real mechanism, but not yet a clean prescription: no sleep-timing trial has actually genotyped participants and tested whether slow metabolizers need a bigger safety margin than the standard six-hour rule. Until that trial exists, treat “know your own sensitivity” as a stand-in for a genotype you probably don’t know.

Treat six hours as a floor, not a target. A small coffee mid-afternoon likely costs little; a large coffee or energy drink after lunch can still be cutting into deep sleep at bedtime. If you already sleep poorly, or know caffeine hits you hard, push your last dose earlier and judge by how you actually sleep, not the clock.

← More in Recovery