Free tool

Sleep calculator

Enter the time you need to wake up and get bedtimes that fit whole sleep cycles, or enter a bedtime and get wake-up times. Each option is checked against the 7 to 9 hours the NHS says most adults need.

Figures checked See sources

  1. When you wake up, or when you go to bed
  2. How long you take to fall asleep

Free, with no sign-up. Nothing you enter is saved.

Free tool

Sleep calculator

What do you know?
How long you usually take to fall asleep

Your bedtimes

To wake at 7am, go to bed at

  • 9:45pm6 cycles, 9 hoursWithin the NHS 7 to 9 hours
  • 11:15pm5 cycles, 7 and a half hoursWithin the NHS 7 to 9 hours
  • 12:45am4 cycles, 6 hoursUnder 7 hours

These times assume 90 minute sleep cycles (cycles run 80 to 100 minutes) and 15 minutes to fall asleep, so the bedtime is when to get into bed. Your own cycles vary from night to night, so treat them as a guide.

Evening sun casting soft stripes on a bedroom wall above a small clock and a plant
Photo by Brandon Cormier on Unsplash

How the sleep calculator works

Sleep runs in cycles. The US National Heart, Lung, and Blood Institute (NHLBI) says a cycle starts over every 80 to 100 minutes, and that most nights have four to six of them. The calculator takes 90 minutes, the middle of that range, as one cycle.

  • If you know when you need to wake up, it counts back 6, 5 and 4 cycles (9, 7 and a half, and 6 hours) and then takes off the time you usually need to fall asleep. That gives you three bedtimes.
  • If you know when you are going to bed, it counts forward the same way and gives you three wake-up times. Press "use the time now" if you are going to bed straight away.

The time to fall asleep is set to 15 minutes. Change it to 5 or 30 if that is closer to how long you usually lie there.

For example, to wake at 7am with 15 minutes to drop off, the bedtimes are 9:45pm (6 cycles), 11:15pm (5 cycles) and 12:45am (4 cycles).

What happens in a sleep cycle

Each cycle moves through three stages of non-REM sleep and then a stretch of REM sleep, the stage when most dreaming happens. Stage 3 is deep sleep, also called slow-wave sleep. The NHLBI says you usually spend more time in deep sleep early in the night, and have more REM sleep later on. So the cycles are not identical: those early in the night hold more deep sleep, and later ones more REM.

Why wake at the end of a cycle?

The groggy, slow feeling just after you wake is called sleep inertia. A 2019 review of the research found it is worse when you wake from deep sleep. In one of the studies it describes, people woken from slow-wave sleep after a nap performed 41% worse than they had before the nap, while people woken from lighter stage 2 sleep performed about the same as people who had stayed awake.

That is the idea behind timing your alarm to the end of a cycle. It is a rough guide rather than a precise one, because your cycles vary in length from night to night, and you can't know exactly when you fell asleep.

How much sleep do I need?

The NHS says adults need 7 to 9 hours a night and children 9 to 13 hours. Five or six cycles fall in the adult range. Four cycles is 6 hours, which is less than most adults need, so the calculator flags it.

If one of the cycle-based bedtimes means less sleep than you need, pick the earlier one.

If you can't sleep

The NHS advice for poor sleep includes going to bed only when you're sleepy, waking up and getting out of bed at the same time every day, and not sleeping in after a bad night but sticking to your regular hours. A fixed wake-up time is the easiest place to start, which is why the calculator begins with it.

See a GP if changing your sleep habits hasn't helped, you've had trouble sleeping for months, or it is affecting your daily life in a way that makes it hard to cope.

For what the research says about magnesium, read magnesium and sleep. If you're thinking about a sleep supplement, melatonin in the UK explains where it stands here, and sleep supplements in the UK covers the rest. If you drink coffee or tea in the afternoon, the caffeine calculator adds up how much caffeine you have in a day.

Common questions

What time should I go to bed to wake up at 7am?

If you take about 15 minutes to fall asleep, 9:45pm gives you 6 full cycles (9 hours) and 11:15pm gives you 5 cycles (7 and a half hours). Both are within the 7 to 9 hours the NHS says most adults need.

What time should I go to bed to wake up at 6am?

With 15 minutes to fall asleep, 8:45pm gives you 9 hours (6 cycles) and 10:15pm gives you 7 and a half hours (5 cycles).

How long is a sleep cycle?

The NHLBI puts a full cycle at 80 to 100 minutes, with four to six cycles in a usual night. The calculator uses 90 minutes as an average.

Is 6 hours of sleep enough?

For most adults, no. The NHS says adults need 7 to 9 hours. Six hours is four full cycles, so you might wake more easily, but you would still be short of the usual amount.

Sources

  1. NHLBI (US National Institutes of Health): Sleep phases and stages
  2. NHS: Insomnia
  3. Hilditch and McHill. Sleep inertia: current insights, Nature and Science of Sleep (2019)

These tools give general information, not medical advice. If you have a medical condition, take prescription medicines, or are pregnant or breastfeeding, speak to your GP, pharmacist or a dietitian.

Further reading

  • Vitamins and minerals

    Does magnesium help you sleep?

    For most people, not by much. The trials are small and mixed, the clearest signal is in older adults and people who get little magnesium from food, and even there the effect is modest.

    11 min read

  • Sleep and mind

    Can you buy melatonin in the UK?

    Not over the counter. Melatonin is a prescription-only medicine in the UK, so no shop, website or pharmacy (Boots included) can sell it to you without a prescription, and the NHS says the melatonin supplements sold in other countries aren't authorised for sale here.

    11 min read

More free tools

  • Caffeine calculator

    Add up the caffeine in a normal day of coffee, tea, cola, energy drinks and chocolate, and see how it compares with UK and European limits. Every figure comes from the NHS, EFSA, a UK study or the drink's own UK label.

  • Protein calculator

    Enter your weight in kilograms or stone and see how much protein you need a day: the UK reference amount, and the higher ranges research suggests if you train regularly or are over 65.

  • Fibre calculator

    Add up the fibre in a normal day of everyday UK foods and see how close you come to the 30 g a day the UK recommends for adults. Figures come from the UK's official food composition data, per typical portion.

  • Creatine calculator

    Work out a daily creatine dose, or a loading dose scaled to your weight, and how much water it takes to dissolve. The numbers come from the International Society of Sports Nutrition's position stand and published solubility data.

  • Vitamin unit converter

    Convert micrograms, milligrams and grams, or switch vitamin D, A and E between international units (IU) and mcg or mg. Each result is shown next to the NHS daily amounts for that vitamin.