Caffeine & Sleep
Cutoff Calculator
Caffeine has a half-life of about five hours — half of your afternoon coffee can still be circulating at midnight. See what's left at bedtime and when your last cup should be.
Your intake
Caffeine remaining at bedtime
Decay from now to bedtime
How this works
Methodology reviewed July 2026Caffeine clears from the body by first-order decay — a roughly fixed fraction leaves every few hours. The tool models how much of each dose is still circulating at bedtime using an exponential half-life curve, then works backward to the latest your last cup should be to keep bedtime caffeine below a sleep-friendly threshold.
remaining (mg) = dose × 0.5 ^ (hours elapsed / half-life)
default half-life ≈ 5 hours (individual range ~3–7 h)
Caffeine doses and times · Bedtime · Optional half-life
Caffeine still circulating at bedtime · Recommended last-cup time
- A ~5-hour half-life; yours shifts with genetics, pregnancy, smoking, and some medications.
- All caffeine is absorbed and decays from its intake time.
- Individual clearance varies two-fold or more, so treat the cutoff as a guide, not a guarantee.
- Sensitivity to a given circulating amount also varies between people.
- This estimates caffeine levels for sleep planning; it is not medical advice about caffeine intake.
This calculator is for educational purposes only and is not medical advice, diagnosis, or treatment. Results are estimates based on published formulas and population averages — your individual values may differ. Nothing here is calculated on a server: everything runs in your browser and no data is stored or sent anywhere. Always consult a qualified clinician before making health, medication, or training decisions.