Sleep Hygiene Tools

Caffeine Half-Life Calculator

That 2 PM cold brew might still be half-active at midnight. Plug in what you drank, when you drank it, and how your body metabolizes caffeine — and find out exactly where you stand right now.

Calculator

Adjust sliders or tap a drink to get your result instantly.

Caffeine Consumed200 mg
Hours Since Last Drink4 hrs
Now6h12h18h24h

Your Metabolism Type

Stacked Doses

Caffeine Still Active

0mg
Cleared from system0%
Low Concentration
Estimated safe bedtime
Half-life used5.5h (Average)

Caffeine at this level has minimal impact...

Caffeine Decay Curve (24 hours)

Red dots = additional doses • Blue line = total caffeine level

Timeline Breakdown

+6h from now60.4 mg
+11h from now30.2 mg
+17h from now15.1 mg

What the half-life actually means in practice

Most people have a rough sense that caffeine "wears off" — but the half-life concept is more nuanced than it sounds. It doesn't mean the caffeine is gone in 5 or 6 hours. It means half of it is gone. The other half keeps going through another half-life, leaving a quarter. Then an eighth. It's an exponential decay, and that tail matters for sleep.

Here's a concrete example. Say you drink a 200mg coffee at 1:00 PM:

TimeCaffeine RemainingRough Equivalent
1:00 PM (consumed)200 mgTwo shots of espresso
6:30 PM (5.5h later)100 mgOne full espresso
12:00 AM (11h later)50 mgHalf an espresso
5:30 AM (16.5h later)25 mgA third of a green tea

For most adults aiming for a 10:30 PM bedtime, that single afternoon coffee is still sitting at roughly 50mg when their head hits the pillow. That's not nothing.

The sleep science part people miss

The common pushback here is: "I drink coffee all day and sleep fine." That may be true in a narrow sense — you fall asleep, you wake up, you function. But there's a layer beneath that which sleep labs have been documenting for decades.

Caffeine's primary mechanism is blocking adenosine receptors. Adenosine is the molecule your brain accumulates across the waking day — the biological signal for "time to sleep." The more it builds up, the stronger the pressure to rest. Caffeine doesn't remove that pressure; it blocks the sensor. The adenosine is still there, waiting.

Where this matters most is in N3 sleep — the deepest, slowest-wave stage. This is where your brain consolidates memories, your body releases growth hormone, and your glymphatic system clears metabolic waste. A 2013 study in the Journal of Clinical Sleep Medicine found that caffeine consumed six hours before bed cut total sleep time by more than an hour even when participants reported no subjective difficulty falling asleep.

So if you're sleeping but feel like sleep isn't doing much for you, afternoon caffeine is the first variable worth controlling.

The quarter-life rule of thumb

If the half-life is 5.5 hours, 25% of caffeine remains after 11 hours. For a 10:00 PM bedtime, your last dose should ideally land before 9:00 AM to fall below ~25mg. For most people a practical target is finishing caffeine by 1–2 PM. Use the calculator above to find your personal cutoff based on your metabolism type.

Why your half-life isn't the same as your friend's

The 5 to 6 hour figure is a population average. Real-world variation is significant, and it's mostly genetic. The main player is a liver enzyme called CYP1A2, responsible for about 95% of caffeine metabolism.

Fast metabolizers can clear a cup of coffee in 3 to 4 hours. Slow metabolizers might carry the same dose for 8 to 10 hours. You can get a rough sense from experience — does caffeine seem to hit hard and linger, or does it evaporate quickly?

Beyond genetics, a few other factors matter. Smoking significantly speeds up CYP1A2 activity. Pregnancy slows caffeine clearance so much that by the third trimester, the half-life can reach 15 hours or more. Oral contraceptives have a similar effect. Liver disease and some medications — certain antibiotics and antidepressants — also slow clearance.

Fast Metabolizer

~3.5h half-life

CYP1A2 fast variant or heavy smoker. 200mg coffee mostly cleared in ~7 hours.

Average Adult

~5.5h half-life

Most healthy adults. 200mg coffee mostly cleared in ~11 hours.

Slow Metabolizer

~7.5h half-life

CYP1A2 slow variant or on some medications. 200mg coffee mostly cleared in ~15 hours.

Pregnant / On the Pill

~10h half-life

Oral contraceptives or pregnancy significantly extend clearance. Morning coffee may still be active at bedtime.

Stacking doses matters more than any single drink

One morning coffee usually isn't the problem. The issue is stacking — a morning coffee, an afternoon latte, maybe a pre-workout in the evening. Each dose starts its own independent decay curve, and they add together. By 10 PM you might be carrying the tail end of three different caffeine exposures simultaneously.

That's why the calculator above includes a stacked-dose input. If you want an accurate picture of what's actually in your system, account for everything you drank that day — not just the last drink.

Frequently asked questions

How long does caffeine stay in your system?

For most healthy adults, caffeine has a half-life of 5 to 6 hours. Full clearance below a level that noticeably affects sleep takes around 10 to 12 hours. People with slower metabolism, or who are pregnant or on certain medications, may take considerably longer.

What caffeine level is safe before bed?

There's no hard universal number since sensitivity varies. Researchers often use 40mg as a working threshold — roughly the caffeine in a weak cup of green tea — below which sleep architecture isn't meaningfully disrupted for most people. If you're sensitive, aim lower.

What time should I stop drinking coffee?

For most adults with a 10–11 PM bedtime, stopping caffeine by 1–2 PM is a practical target. This accounts for the average 5.5-hour half-life and allows caffeine to drop below 40mg before sleep. If you're a slow metabolizer, you may need to stop earlier — use the calculator above for a personalized estimate.

Can I feel fine but still have bad sleep from caffeine?

Yes, and this is arguably the most underappreciated aspect of caffeine and sleep. You can fall asleep without difficulty while active caffeine is still reducing your N3 deep sleep. The deficit shows up as reduced cognitive recovery and physical restoration — not necessarily obvious insomnia.

Does tolerance reduce caffeine's sleep impact?

Tolerance reduces the alerting effect of caffeine, but research suggests it doesn't fully protect sleep quality. Regular caffeine users still show measurable reductions in slow-wave deep sleep compared to non-users, even when they no longer feel wired before bed.

How does caffeine work in the brain?

Caffeine blocks adenosine receptors. Adenosine builds up throughout the day as a natural sleep pressure signal. Caffeine doesn't remove that pressure — it blocks the sensor that detects it. When caffeine clears, all the built-up adenosine binds at once, which is why caffeine crashes can feel sudden.

Does decaf coffee have caffeine?

Yes, but much less. A typical 8oz cup of decaf contains 2–15mg of caffeine depending on the brand and brewing method. For most people this is negligible, but for slow metabolizers or those who are very sensitive, even decaf in the evening can have a small effect.

Content reviewed and updated . Based on published sleep and pharmacology research.