Free tools /

Caffeine Half-Life & Sleep Calculator

A caffeine half life calculator for bedtime. Enter how many mg you had, when you had it and when you plan to sleep, and see how much caffeine is still in your system at bedtime, the share of the dose that is left, and when it falls to 50 mg.

The mean for healthy adults. The normal range is roughly 3–7 hours. These are population averages, not personal predictions.

Left at bedtime

iPhone & iPad · Free

Track it in Caffeine Tracker.

Log every coffee, tea and energy drink against a daily limit and watch the decay curve run to your bedtime.

Stay under your caffeine limit — Caffeine Tracker on iPhone showing live body caffeine against the daily limit

How the caffeine half-life calculation works

A half-life is the time it takes for half of what you took to be cleared. In healthy adults caffeine's mean half-life is about 5 hours, with a normal range of roughly 3 to 7 hours. Because each half-life removes half of what is left rather than a fixed amount, the decay is exponential: a 200 mg coffee at 3 PM is down to 100 mg at 8 PM, 50 mg at 1 AM and 25 mg at 6 AM.

That is also the honest answer to how long caffeine stays in your system: it never reaches exactly zero, it just keeps halving. After about five half-lives roughly 3 percent of the dose is left, which is the point a drug is usually treated as cleared. At a 5-hour half-life that is around 25 hours, so a large afternoon dose can still be measurable the following morning.

For the sleep side, a controlled trial found that 400 mg taken 6 hours before bed still measurably disrupted sleep (Drake et al., 2013), which is where the common advice to leave a six-hour gap comes from. The FDA states that 400 mg a day is not generally associated with negative effects for healthy adults. This calculator reports your numbers against those references and leaves the judgement to you.

remaining mg = dose × 0.5 ^ (hours elapsed ÷ half-life)

Half-life varies widely between people, and the options in the selector are population averages rather than personal predictions. Smoking induces the CYP1A2 enzyme and roughly halves caffeine's half-life to about 3 hours; combined oral contraceptives roughly double it to about 10 hours; in the third trimester of pregnancy it can stretch to about 15 hours. Age, liver function, genetics and other medicines all move the number too, so treat any result as a range rather than a reading.

Caffeine half-life calculator FAQ

How long does caffeine stay in your system?

Longer than most people expect. With a 5-hour half-life, half of a dose is still present after 5 hours, a quarter after 10 and an eighth after 15. Around five half-lives, roughly 25 hours for a typical adult, about 3 percent is left and it is usually treated as cleared.

What is caffeine's half-life?

About 5 hours on average in healthy adults, with a normal range of roughly 3 to 7 hours. The calculator uses 5 hours by default and lets you switch to the documented population modifiers instead.

Why do smokers clear caffeine faster?

Smoking induces CYP1A2, the liver enzyme that metabolises most caffeine. That roughly halves the half-life to about 3 hours, so the same coffee leaves a smoker's system sooner. Quitting reverses the effect, which is why coffee can suddenly feel stronger after stopping.

Does caffeine tolerance change how fast I clear it?

No, not meaningfully. Tolerance is an adaptation in how your brain's adenosine receptors respond, not a change in how quickly your liver metabolises caffeine. A habitual drinker may feel less from a dose, but the half-life and the amount still circulating at bedtime are about the same.

How many hours before bed should I stop drinking coffee?

This tool does not set a threshold for you. What the evidence shows is that 400 mg taken 6 hours before bed still measurably disrupted sleep in a controlled trial (Drake et al., 2013). Use the mg remaining at bedtime and that finding to decide what works for you.