Eight to ten hours before bed is the safe cutoff for most people, and six hours is the bare minimum worth trying. How long before bed you should stop drinking caffeine comes down to one number: its half-life is roughly five hours, so half of an afternoon coffee is still circulating at bedtime.

That arithmetic is the whole answer, and it is why a 3pm coffee matters more than people expect. Our caffeine cutoff calculator works it out from your own bedtime.

A Quick Note

This is general information about caffeine timing, not medical advice. Caffeine sensitivity varies enormously between people and is affected by medication, pregnancy, liver function and genetics. Anyone with a heart condition, an anxiety disorder or persistent insomnia should raise caffeine intake with a doctor rather than self-managing it.

Quick Answer

Count back eight to ten hours from your target bedtime and make that your last caffeine of the day. For an 11pm bedtime that means roughly 1pm to 3pm. Six hours is the minimum that produces a noticeable difference. Sensitive people, slow metabolizers and anyone already sleeping badly should push the cutoff earlier rather than later.

Key Takeaways

  • Caffeine’s half-life is roughly five hours, with a wide individual range.
  • Half of a 3pm dose is still active at 8pm and a quarter at 1am.
  • Eight to ten hours before bed suits most people.
  • Caffeine can flatten deep sleep without stopping you falling asleep.
  • Decaf is not caffeine-free, and neither is chocolate or some tea.
  • Tolerance to alertness is not tolerance to sleep disruption.
BedtimeConservative cutoffMinimum cutoff
9:00 pm11:00 am to 1:00 pm3:00 pm
10:00 pm12:00 pm to 2:00 pm4:00 pm
11:00 pm1:00 pm to 3:00 pm5:00 pm
12:00 am2:00 pm to 4:00 pm6:00 pm
1:00 am3:00 pm to 5:00 pm7:00 pm

The Half-Life Is the Mechanism

Half-life means the time your body takes to clear half of a dose. For caffeine that is around five hours in a healthy adult, with a normal range spanning roughly three to seven.

The consequence is arithmetic rather than opinion. A dose at 3pm is half-cleared by 8pm, a quarter remains at 1am, and an eighth is still there at 6am.

That residual quarter is not nothing. It is the equivalent of drinking a quarter of a cup of coffee at bedtime.

Doubling the dose doubles what is left at every point along that curve, which is why a large afternoon coffee behaves very differently from a small one.

Why It Disrupts Sleep Even When You Fall Asleep Fine

Caffeine works by blocking adenosine receptors. Adenosine is the molecule that accumulates through the day and creates the pressure to sleep.

Blocking those receptors does not remove the adenosine. It masks the signal, which is why the tiredness arrives all at once when caffeine wears off.

The part people miss is that falling asleep and sleeping well are separate outcomes. Caffeine in your system can reduce deep sleep and increase brief awakenings while still letting you drop off at a normal time.

That produces a full night in bed that does not feel restorative. Our guide to understanding sleep cycles covers which stages get hit.

Individual Variation Is Large

Genetics

The liver enzyme that clears caffeine varies between people. Fast metabolizers clear a dose in a few hours; slow metabolizers take considerably longer.

Medication and pregnancy

Some medications slow caffeine clearance substantially, and pregnancy extends the half-life. Both push the cutoff earlier.

Smoking

Smoking speeds caffeine clearance, which is why quitting can make the same coffee feel much stronger.

Age and regular intake

Clearance tends to slow with age. Regular intake builds tolerance to the alertness effect without matching tolerance to the sleep disruption.

Where the Caffeine Actually Is

Brewed coffee is the obvious source and the largest single one for most people. Espresso has more per ounce and less per serving.

Tea is often underestimated. Black tea carries a meaningful dose and green tea a smaller one, and both add up over an afternoon.

Decaf is not caffeine-free. It contains a small residual amount, which matters only if you are drinking several cups late.

Then the hidden ones: dark chocolate, cola, energy drinks, pre-workout supplements, some pain relievers and some weight-loss products. The U.S. Food and Drug Administration notes that 400 milligrams a day is generally not associated with dangerous negative effects in healthy adults, which is a daily ceiling rather than a timing rule.

Setting a Cutoff You Will Keep

  1. Count back from bedtime, not from dinner. Eight to ten hours before the time you actually go to sleep.
  2. Write down the clock time. A time is easier to follow than a rule about hours.
  3. Move it in one step, not gradually. A vague intention to cut back earlier rarely survives an afternoon slump.
  4. Substitute rather than subtract. Our roundup of herbal teas for sleep covers the replacement.
  5. Expect two or three rough afternoons. The adenosine that was being masked is still there.
  6. Audit the hidden sources. Chocolate, cola and pre-workout all count toward the same clock.
  7. Give it two weeks before judging. One night tells you very little about sleep quality.

Our guide to fixing your sleep schedule covers doing this alongside the other timing changes.

The Afternoon Slump Problem

An early cutoff collides with the natural dip in alertness that arrives in the early afternoon. That dip is circadian rather than a caffeine withdrawal effect.

A short nap addresses it more effectively than caffeine does, and without any effect on the night. Our guide to how long a nap should be covers the duration that avoids grogginess.

Light exposure works too. Getting outside for even a few minutes in the early afternoon shifts alertness without adding anything to your system.

Our guide to how naps affect night sleep covers the timing that keeps a nap from costing you the night.

If the Cutoff Does Not Help

Caffeine is one input among several, and moving it does not fix a schedule that is wrong in other ways.

Alcohol, screens, late exercise and bedroom temperature all act on the same night. Our guide to what time you should go to sleep covers the anchor the rest of it hangs off.

Persistent difficulty falling or staying asleep despite a sensible caffeine cutoff is worth treating as its own problem rather than a caffeine problem.

Our guide to dealing with insomnia naturally covers the non-pharmacological approaches, and a clinician is the right next step when those are not enough.

Sources

  • U.S. Food and Drug Administration, guidance on caffeine intake for healthy adults
  • American Academy of Sleep Medicine, patient guidance on sleep hygiene and caffeine

Frequently Asked Questions

How long before bed should you stop drinking caffeine?

Eight to ten hours before bed for most people, with six hours as the minimum worth attempting. The reason is caffeine’s half-life of roughly five hours, which leaves a quarter of an afternoon dose still circulating well after midnight.

Is 2pm too late for coffee?

It depends on your bedtime. For an 11pm bedtime, 2pm sits inside the conservative window and is reasonable. For a 9pm bedtime it is late, since roughly a quarter of the dose would still be active when you are trying to sleep.

Why can I fall asleep after coffee but sleep badly?

Because falling asleep and sleeping well are separate outcomes. Caffeine still in your system can reduce deep sleep and add brief awakenings without preventing sleep onset, which produces a full night that does not feel restorative.

Does tolerance mean caffeine stops affecting my sleep?

No. Regular intake builds tolerance to the alertness effect, so the same coffee wakes you up less. Tolerance to the sleep disruption does not develop to the same degree, so the night can still be affected even when the coffee feels mild.

Is decaf actually caffeine-free?

No, it contains a small residual amount. One cup late in the evening is unlikely to matter for most people. Several cups late can add up to a dose worth accounting for if you are particularly sensitive.

What about tea and chocolate?

Black tea carries a meaningful amount and green tea less, and both accumulate across an afternoon. Dark chocolate, cola, energy drinks, pre-workout supplements and some pain relievers all contribute to the same clock and are easy to overlook.

How long does it take to adjust to an earlier cutoff?

Expect two or three uncomfortable afternoons, because the adenosine that caffeine was masking is still present and the tiredness surfaces. Judge the effect on your sleep after about two weeks rather than after one night.

When should you see a doctor about this?

See a doctor if you cannot function without large amounts of caffeine, if you have a heart condition or anxiety disorder and are using it heavily, or if sleep stays poor after a sensible cutoff for several weeks. Caffeine clearance is also affected by several medications worth reviewing.