Find a course

Module 2: Light, Caffeine and Your Body ClockLesson 5 of 1212 min

Caffeine, Alcohol and Sleep

Calculate how much caffeine is still in your body at bedtime, see why a nightcap backfires, and learn how nicotine and other substances affect sleep.

Step 1 of 12Learn

The coffee that's still working at bedtime

Marcus has a large coffee at 4 p.m. to beat his afternoon slump. He goes to bed at 11 p.m., falls asleep after a while and wakes up feeling unrefreshed. He's sure the coffee isn't the problem: "Caffeine doesn't affect me. I can drink a coffee and fall right asleep."

He may well fall asleep. But in sleep lab studies, caffeine taken even six hours before bed reduced total sleep, sometimes by more than an hour, and made sleep lighter, with less deep N3 sleep. Many participants didn't notice the change themselves. Falling asleep is only part of the story; the quality of the night afterward is where much of the cost shows up.

Caffeine is the most widely used psychoactive substance in the world, and in moderation it is safe for most healthy adults. Many health authorities, including the US Food and Drug Administration, cite about 400 mg a day as an amount not generally associated with harmful effects for healthy adults (lower during pregnancy). The issue for sleep is not mainly how much you drink but when. This lesson shows you how to calculate it.

Step 2 of 12Learn

How caffeine works and how long it lasts

Caffeine works by blocking adenosine receptors. Adenosine is the molecule behind sleep pressure. With its receptors blocked, you feel more alert even though the pressure is still building. When caffeine wears off, that hidden pressure arrives all at once.

How long it lasts is described by its half-life: the time it takes your body to clear half of it. For a typical healthy adult, caffeine's half-life is around 5 hours, but it ranges widely, from about 2 to 10 hours depending on genetics, liver function, pregnancy (which slows clearance a lot), some medications and smoking (which speeds it up).

Half-lives multiply, they don't subtract. With a 5-hour half-life, 200 mg becomes 100 mg after 5 hours, 50 mg after 10 hours and 25 mg after 15 hours. The general formula is:

remaining = dose × 0.5^(hours ÷ half-life)

Approximate caffeine contents (they vary by brand and preparation):

DrinkCaffeine
Brewed coffee, 8 oz (240 ml)about 95 mg
Espresso, single shotabout 65 mg
Black tea, 8 ozabout 45 mg
Cola, 12 oz (355 ml)about 35 mg
Energy drinkabout 80–300 mg

Large coffee-shop drinks can contain 300 mg or more. Decaf isn't zero, but usually only a few milligrams.

Step 3 of 12Diagram

How caffeine hides your tiredness

How caffeine hides your tirednessProcess diagram: Adenosine builds all day → Caffeine blocks receptors → Pressure keeps building → Caffeine wears off → All that pressure hits at once.Adenosine builds all dayCaffeine blocksreceptorsPressure keepsbuildingCaffeine wears offAll that pressure hitsat once

Tap a shape with to see more.

Adenosine builds all day
Caffeine blocks receptors

Adenosine cannot dock, so you feel alert.

Pressure keeps building

Caffeine hides the signal; it does not remove the cause.

Caffeine wears off
All that pressure hits at once

Step 4 of 12Try the calculator

Caffeine at bedtime calculator

Enter your caffeine dose, how many hours before bedtime you had it and your estimated half-life. Five hours is a typical starting estimate.

Caffeine left at bedtime
76 mg
Share of the dose still active
38 %
Equivalent in 8 oz coffees
0.8

Step 5 of 12Practice · Work it out

Elena drinks a coffee with 200 mg of caffeine at 3:00 p.m. Her half-life is 5 hours. About how many milligrams remain at 11:00 p.m.? Use the calculator if you like.

Step 6 of 12Practice · Chart

200 mg of caffeine at 3 p.m., 5-hour half-life

Tap the first time shown when less than half of the dose is left.

Tap the point that answers the question, then press Check.

200 mg of caffeine at 3 p.m., 5-hour half-lifeLine chart with 7 categories: 3 pm: 200 mg; 5 pm: 152 mg; 7 pm: 115 mg; 9 pm: 87 mg; 11 pm: 66 mg; 1 am: 50 mg; 3 am: 38 mg.0 mg50 mg100 mg150 mg200 mg3 pm5 pm7 pm9 pm11 pm1 am3 am
200 × 0.5^(hours ÷ 5). Half-lives vary widely between people.
200 mg of caffeine at 3 p.m., 5-hour half-life
ItemCaffeine remaining
3 pm200 mg
5 pm152 mg
7 pm115 mg
9 pm87 mg
11 pm66 mg
1 am50 mg
3 am38 mg

Step 7 of 12Learn

The nightcap problem

Alcohol is a sedative, so it often helps people fall asleep faster. That's why about one in five adults in some surveys report using it as a sleep aid. The problem is what happens next.

First half of the night. Alcohol suppresses REM sleep in the early cycles and can increase deep sleep at first. You're asleep, but the normal architecture is distorted.

Second half of the night. As the liver clears the alcohol, the body swings the other way. Sleep becomes lighter and more broken, with more awakenings, more REM rebound with vivid dreams, sweating, a racing heart and trips to the bathroom, because alcohol suppresses the hormone that limits urine production. Many people wake at 3 or 4 a.m. and can't get back to sleep.

Breathing. Alcohol relaxes the muscles of the throat, which worsens snoring and can turn mild sleep apnea into more severe breathing pauses.

The effect grows with the dose. One drink with an early dinner has a small effect for most people; several drinks close to bedtime reliably damage sleep quality. The body clears roughly one standard drink per hour, so a practical guideline is to stop drinking at least three hours before bed and to avoid using alcohol as a sleep aid at all. If you rely on alcohol to fall asleep, that's a sign the underlying sleep problem deserves real attention.

Step 8 of 12Practice · True or false

Because alcohol helps you fall asleep faster, a few drinks before bed usually improves overall sleep quality.

Step 9 of 12Learn

Nicotine, cannabis and sleeping pills

Nicotine is a stimulant. Smokers and vapers tend to take longer to fall asleep, sleep more lightly and wake more often, partly because nicotine withdrawal builds during the night. An evening cigarette "to relax" relieves withdrawal, not stress. Sleep often gets worse for a few weeks after quitting and then improves beyond the starting point.

Cannabis can shorten the time to fall asleep in the short term, and some people use it nightly for that reason. With regular use, tolerance develops, REM sleep is suppressed, and when people stop, they commonly experience weeks of poor sleep and intense dreams. Research on cannabis products as sleep treatments is still limited and mixed.

Over-the-counter sleep aids in the US usually contain sedating antihistamines such as diphenhydramine or doxylamine. They can cause next-day grogginess, tolerance builds within days, and doctors advise caution in older adults because of risks to memory and balance.

Prescription sleep medications can be useful for short periods or specific situations, but they treat symptoms rather than the causes of insomnia, and some carry risks such as dependence and complex sleep behaviors. Guidelines recommend CBT-I as the first-line treatment for chronic insomnia, with medication as an option discussed with a doctor. Never stop a prescribed medication abruptly without medical advice.

Step 10 of 12Practice · Match the pairs

Match each substance with its main effect on sleep.

Tap an answer, then tap the place where it belongs (or drag it there).

  1. Caffeine
  2. Alcohol
  3. Nicotine
  4. Sedating antihistamines

Step 11 of 12Note

Step 12 of 12Practice · What would you do?

What would you do?

Dev, 38, has trouble staying asleep. His day: two coffees before 9 a.m., an energy drink (about 160 mg) at 4:00 p.m., two glasses of wine with dinner at 9:30 p.m., bed at 11:00 p.m., and he usually wakes around 3:30 a.m. What change is likely to help most?