CaffeineTime

Energy & tiredness

Drinking coffee in the afternoon: is it bad for your sleep?

Sources checked claim by claim by an AI review. Approved for publishing by Oleksii Y. on 2026-10-13. · 5 min read

Drinking coffee in the afternoon is not bad in itself, but the timing matters for sleep. A 2023 meta-analysis suggests having a standard coffee (107 mg) at least 8.8 hours before bed, which is about 2 p.m. for an 11 p.m. bedtime. Caffeine’s half-life averages about four hours and ranges from two to eight, so how long an afternoon cup lingers varies from person to person. For the post-lunch dip, two small studies found caffeine combined with a short nap worked best.

How much will be left at bedtime?

Left at 11:00 PM (8 h later), average metabolism

≈ 35 mg

Range 17–54 mg (fast to slow metabolism)

To be at 50 mg or less by bedtime, have 107 mg by 4:46 PM (average) or 1:28 PM (slow metabolism).

What sleep studies found near this dose

  • Gardiner et al. 2025 (randomized trial): In 23 healthy young men, 100 mg taken 12, 8 or 4 hours before bed had no significant effect on measured or self-rated sleep.
  • Gardiner et al. 2023 (meta-analysis): To avoid losing sleep time, the authors suggest a coffee (107 mg per 250 ml) at least 8.8 hours before bed.

Estimate from a simple model: half-life of 3, 5 or 8 hours, 50 mg bedtime target. How we calculate

Key takeaways

  • A meta-analysis of 24 studies suggests a standard coffee at least 8.8 hours before bed to avoid losing sleep time.
  • A 2025 trial found 100 mg had no significant effect on sleep even 4 hours before bed in young men, while 400 mg within 12 hours did.
  • The post-lunch dip is a real drop in alertness that can happen even without lunch.
  • In two small studies, caffeine combined with a short nap worked better against afternoon sleepiness than a nap alone in one study or caffeine alone in the other.

How late in the afternoon can you drink coffee?

A 2023 meta-analysis of 24 studies gives a guide. To avoid a reduction in total sleep time, it suggests having a standard coffee (107 mg per 250 ml) at least 8.8 hours before bedtime, and a typical pre-workout supplement (217.5 mg) at least 13.2 hours before. The table below applies the 8.8-hour figure to common bedtimes; it is simple arithmetic, not a separate study, and it does not apply to bigger doses.

A 2025 trial in 23 young men adds detail on dose. 100 mg of caffeine taken 12, 8 or 4 hours before bed had no significant effect on sleep, while 400 mg taken within 12 hours of bed delayed sleep and changed its structure. EFSA cautions that even 100 mg may affect sleep in some adults when taken close to bedtime. Enter your own drink and bedtime in the calculator on this page, or use the caffeine cutoff calculator.

Latest time for a standard 107 mg coffee, using the meta-analysis’s 8.8-hour figure
BedtimeLatest standard coffee
9:00 p.m.About 12:10 p.m.
10:00 p.m.About 1:10 p.m.
11:00 p.m.About 2:10 p.m.
MidnightAbout 3:10 p.m.

Why you get sleepy after lunch

The mid-afternoon slump that sends people to the coffee machine has a name: the post-lunch dip. A 2005 review describes it as a real phenomenon that can occur even when someone has had no lunch, with roots in human biology and possibly linked to the body clock. A high-carbohydrate lunch makes it worse. It does not happen to everyone: the review says the dip shows up for some performance measures and some individuals.

That matters for coffee timing, because the dip falls right around the time an afternoon coffee starts to eat into the night. If you often reach for coffee late in the afternoon, the guide to the best time to drink coffee can help you move your caffeine earlier.

Coffee for the afternoon slump: what worked best in studies

Two small studies compared caffeine with a short nap. In one, 10 young adults took a 20-minute nap at 12:40 p.m. with different add-ons; 200 mg of caffeine followed by the nap was the most effective for self-rated sleepiness and performance, and the effect lasted through the hour after the nap. In a driving-simulator study of 12 sleepy people, caffeine combined with a nap of under 15 minutes, both taken during a 30-minute break, cut driving incidents in the afternoon to 9% of placebo levels, compared with 34% for 200 mg of caffeine alone.

These studies are small, and they measured only the hour or two after the nap, so treat them as a useful idea, not a rule. A simulator study is also not an endorsement of driving while sleepy. Our guide to the coffee nap explains how to try it.

What afternoon caffeine can do to your night

The reason for the afternoon cutoff is how long caffeine lasts. EFSA gives an average half-life of about four hours in healthy adults, with a range of two to eight hours, so a slow clearer can carry a good share of a 3 p.m. coffee into the evening. Across 24 studies, caffeine reduced total sleep time by 45 minutes and sleep efficiency by 7%, made falling asleep take about 9 minutes longer and cut deep sleep by about 11 minutes.

You may not notice the damage. The authors of the 2025 trial concluded that people may have difficulty accurately perceiving how caffeine affects their sleep. If an afternoon coffee seems harmless, see caffeine and sleep and how long caffeine lasts.

Common questions

Is 3 p.m. too late for coffee?

It depends on your bedtime and the size of the drink. Using the meta-analysis’s 8.8-hour figure for a standard 107 mg coffee, 3 p.m. suits a bedtime around midnight. For an earlier bedtime, or a large coffee-shop cup, 3 p.m. is likely to be too late for some people.

Does afternoon tea affect sleep as much as coffee?

Tea usually has less caffeine: the FDA lists 71 mg for 12 ounces of black tea and 37 mg for green tea, compared with 113 to 247 mg for brewed coffee. The 8.8-hour figure was worked out for a 107 mg coffee, so it does not tell you an exact time for tea.

Is it better to nap or drink coffee for the afternoon slump?

In two small studies, the combination did best: caffeine combined with a short nap beat a nap alone in one study and caffeine alone in the other. If a nap is not possible, an earlier coffee still keeps more of the caffeine away from your bedtime.

General information, not medical advice

If you feel unwell after caffeine — for example chest pain, a fast or irregular heartbeat that does not settle, fainting, confusion or trouble breathing — get urgent medical help. If you are pregnant or breastfeeding, under 18, take medication, or have a heart, liver or anxiety condition, high blood pressure or a sleep disorder, ask a doctor or pharmacist what amount is right for you.

Sources

  1. Gardiner C, Weakley J, Burke LM, et al. (2023). The effect of caffeine on subsequent sleep: A systematic review and meta-analysis. Sleep Medicine Reviews, 69, 101764. doi:10.1016/j.smrv.2023.101764 ↗
  2. Gardiner CL, Weakley J, Burke LM, et al. (2025). Dose and timing effects of caffeine on subsequent sleep: a randomized clinical crossover trial. Sleep, 48(4), zsae230. doi:10.1093/sleep/zsae230 ↗
  3. European Food Safety Authority (2015). EFSA explains risk assessment: Caffeine. European Food Safety Authority (doi:10.2805/618813). efsa.europa.eu (PDF) ↗
  4. Monk TH. (2005). The post-lunch dip in performance. Clinics in Sports Medicine, 24(2), e15–e23. PMID 15892914 ↗
  5. Hayashi M, Masuda A, Hori T. (2003). The alerting effects of caffeine, bright light and face washing after a short daytime nap. Clinical Neurophysiology, 114(12), 2268–2278. PMID 14652086 ↗
  6. Reyner LA, Horne JA. (1997). Suppression of sleepiness in drivers: combination of caffeine with a short nap. Psychophysiology, 34(6), 721–725. PMID 9401427 ↗
  7. U.S. Food and Drug Administration (2024). Spilling the Beans: How Much Caffeine is Too Much? FDA Consumer Updates. fda.gov ↗

An app for better sleep is on the way

We’re working on a mobile app to help you sleep better. It isn’t out yet. Leave your email and we’ll let you know when it launches.