Caffeine Half-Life Calculator

How much caffeine is still in your system right now?

Find out when caffeine will clear your system for better sleep. Enter the amount of caffeine consumed and when you had it — see current caffeine levels, half-life timeline, and when 25mg or less remains. Assumes standard 5-hour half-life for healthy adults.

Updated June 2026 · How this works

Worth knowing
How It Works
The formula, explained simply

Your liver processes caffeine like a biological timer, eliminating exactly half every 5 hours regardless of how much you consumed. This creates a predictable decay pattern - 200mg becomes 100mg after 5 hours, 50mg after 10 hours, 25mg after 15 hours. The surprising part is that caffeine's sleep interference threshold is much lower than most people expect.

This calculator assumes a standard 5-hour half-life for healthy adults. Factors like smoking (shortens to 3-4 hours), pregnancy (extends to 10+ hours), certain medications, and liver conditions can significantly change this timeline. If you consistently have trouble sleeping after afternoon caffeine, your personal half-life may be longer than average.

The 25mg threshold represents the point where most people can sleep normally, though individual sensitivity varies. Some people notice sleep disruption at even lower levels, while others tolerate higher amounts. The calculator shows when levels drop below both 25mg (general sleep threshold) and 6.25mg (near-complete clearance) to help you plan your caffeine timing.

When To Use This
Right tool, right situation

Use this calculator when planning afternoon or evening activities that involve caffeine, especially if you have trouble sleeping. It is most valuable for people who want to enjoy coffee or energy drinks later in the day without disrupting sleep. The tool works best for healthy adults with regular sleep schedules who want to optimize their caffeine timing.

The calculator is particularly useful for shift workers, students during exam periods, and anyone with variable schedules who needs to balance alertness with sleep quality. It helps answer specific timing questions like 'Can I have coffee at 3 PM and still sleep by 11 PM?' or 'How late can I drink my pre-workout and not affect tonight's sleep?' These real-world timing decisions are where the tool provides the most value.

Do not rely on this calculator if you take medications that affect caffeine metabolism, have liver conditions, or are pregnant. These factors significantly change caffeine clearance rates beyond what the standard half-life adjustment can account for. The calculator also assumes you are not a regular heavy caffeine user, as tolerance affects sensitivity to remaining caffeine levels even if elimination rates stay constant.

Common Mistakes
Why results sometimes look wrong

The biggest mistake is underestimating caffeine content in energy drinks and pre-workout supplements. A 16oz energy drink often contains 150-300mg of caffeine - equivalent to 2-3 cups of coffee. Many people treat it as 'one drink' when planning sleep timing, not realizing they consumed a full day's worth of caffeine. Always check the label and calculate based on total milligrams, not number of drinks.

Another common error is ignoring cumulative effects from multiple caffeine sources throughout the day. Morning coffee (95mg) plus afternoon tea (40mg) plus chocolate (20mg) creates overlapping elimination curves. The calculator works for single doses, but multiple doses require adding the remaining amounts from each consumption time. This cumulative buildup often explains why people can't sleep despite having their 'last coffee' many hours earlier.

People also frequently misjudge their personal caffeine sensitivity and half-life. The standard 5-hour half-life is an average - your actual rate could be 3 hours or 8 hours depending on genetics and lifestyle factors. If you consistently have sleep problems after following the calculator's predictions, track your actual sleep quality against caffeine timing to determine your personal clearance rate.

The Math
Worked examples and deeper derivation

The caffeine elimination formula follows exponential decay: Remaining = Initial × (0.5)^(time/half-life). For a 95mg coffee with a 5-hour half-life consumed 3 hours ago: 95 × (0.5)^(3/5) = 95 × 0.715 = 68mg remaining. This exponential pattern means caffeine never fully disappears but becomes negligible over time.

Half-life is the key parameter - it determines how quickly the exponential decay occurs. A 3-hour half-life (smokers) eliminates caffeine much faster than a 7-hour half-life (some medications). The mathematics work the same way, but the timeline changes dramatically. After 12 hours, someone with a 3-hour half-life has eliminated 93.75% of their caffeine while someone with a 7-hour half-life has only eliminated 75%.

The sleep interference calculation uses logarithms to work backwards from the threshold. To find when 95mg drops to 25mg with a 5-hour half-life: time = 5 × log₂(95/25) = 5 × 1.93 = 9.6 hours. This reverse calculation helps predict sleep timing rather than just current levels.

Afternoon Coffee Impact
95mg coffee at 2 PM, checked at 8 PM (6 hours later)
47mg remains in your system, which may delay sleep onset by 30-60 minutes.
Pre-workout Energy Drink
200mg energy drink at 6 PM, checked at 10 PM (4 hours later)
126mg still active, likely to interfere with sleep until after midnight.
Morning Coffee Clearance
95mg coffee at 7 AM, checked at 10 PM (15 hours later)
8mg remains, well below sleep interference threshold for most people.
Expert Unlock
The thing most explanations skip

The 25mg sleep threshold comes from sleep lab studies, but caffeine's actual sleep impact varies by timing within your circadian rhythm. Consuming caffeine 6 hours before your usual bedtime disrupts sleep even if levels drop below 25mg, because caffeine blocks adenosine receptors that accumulate sleep pressure throughout the day. Practitioners use 'caffeine curfew' times (typically 2 PM) rather than just half-life calculations for sleep optimization.

How accurate is caffeine half-life for sleep planning?

How long should I wait after coffee to sleep normally?
Most people need caffeine levels below 25mg for normal sleep, which takes about 6-8 hours after a standard cup of coffee. Individual sensitivity varies - some people can sleep with higher levels while others need longer clearance times.
Why does caffeine affect some people longer than others?
Caffeine half-life ranges from 3-10 hours depending on genetics, age, pregnancy, smoking, and liver function. Smokers clear caffeine faster (3-4 hours) while pregnant women may take 10+ hours. The standard 5-hour half-life applies to healthy non-smoking adults.
Does the type of caffeinated drink matter for sleep timing?
The caffeine amount matters more than the source. A 95mg coffee and 95mg energy drink clear at the same rate, but energy drinks often contain 150-300mg per serving. Check labels carefully as caffeine content varies widely between brands and serving sizes.

Need something this doesn't cover?

Suggest a tool — we'll build it →