Midline

Sleep and stress

How Long Before Bed Should You Stop Caffeine?

By Midline. First published . Last reviewed .

The question

How long before bed should you stop having caffeine?

Short answer

Early in the afternoon, well before bed. Michael Breus says to stop coffee by about 2 pm, because caffeine has a half-life of six to eight hours.

Why does caffeine still affect you hours later?

Because it hangs around. Michael Breus, on The Diary Of A CEO, says caffeine has a half-life of six to eight hours. He says people who stop drinking coffee late in the day have fewer sleep problems.

So when should you have your last coffee?

Have your last caffeine early in the afternoon, well before bed. Michael Breus, The Diary Of A CEO, says to stop coffee by about 2 pm.

Our default is early in the afternoon, well before bed.

The episodes in our library agree on the direction. On a February 2026 Diary of a CEO episode about sleep, Michael Breus's cut-off was about 2 pm, because caffeine lingers for hours. On a November 2025 episode, Matthew Walker listed caffeine next to alcohol as one of the things people take that work against their sleep.

What if you rely on an afternoon coffee?

Move it earlier a little each week rather than all at once. That's our suggestion, not a tested plan.

If the afternoon slump is the real problem, a short walk after lunch is a caffeine-free option.

Check first: if you're pregnant, trying to get pregnant or breastfeeding, take any medicine, or have a sleep disorder, anxiety, high blood pressure, a heart rhythm problem or reflux, ask your doctor how much caffeine is right for you. If poor sleep has gone on for months or affects your days, see your doctor. And if you're waking in the night, caffeine timing is one of the first things to check.

Try this today

Work out your caffeine cut-off: pick a time early in the afternoon, well before your usual bedtime. Set a phone reminder for that time, and switch to water or a caffeine-free drink after it.

Frequently asked questions

How long does caffeine stay in your system?

Michael Breus says caffeine has a half-life of six to eight hours, which is why he says to stop coffee by about 2 pm.

Is 2 pm too late for coffee?

For a 10 pm bedtime, no. Michael Breus says to stop coffee by about 2 pm. If caffeine keeps you up anyway, move it earlier.

Is caffeine OK if I'm pregnant?

Ask your doctor or midwife if you're pregnant, trying to get pregnant or breastfeeding.

Sources

  1. Michael Breus on The Diary Of A CEO. Michael Breus, The Diary Of A CEOStop coffee by about 2 pm. He says caffeine has a half-life of six to eight hours, and 2 pm is about eight hours before a 10 pm bedtime.
  2. Matthew Walker on The Diary Of A CEO. Matthew Walker, The Diary Of A CEOLists caffeine next to alcohol as one of the things people take that work against their sleep.

All sources across the site are listed on the sources page.

Watch the episode

Last reviewed . Educational only, not medical advice. Check with your pharmacist if you take medication.

We draft articles with AI help. A reviewer checks every health statement against the expert's own words in the video before it goes up.

Related articles