What the Sleep Calculator does
This sleep calculator suggests bedtimes for the time you need to wake up - or wake-up times for when you go to bed - by counting back or forward in whole sleep cycles of about 90 minutes, plus the minutes you usually take to fall asleep. Each option shows how many hours of sleep it gives and whether that meets the recommended amount for your age, and a button takes you to the online alarm clock.
The 90-minute cycle is a rule of thumb, not a measurement of your own sleep: real cycles run from roughly 80 to 120 minutes and change through the night. Treat the times as a sensible starting point rather than a precise prescription. The age guidance comes from the consensus recommendations of the American Academy of Sleep Medicine and the National Sleep Foundation, as tabulated by the US Centers for Disease Control and Prevention.
How to use it
- Choose what to calculate: a bedtime for a wake-up time, a wake-up time for a bedtime, or what happens if you go to sleep now.
- Enter the time, then how many minutes you usually take to fall asleep. Fifteen is a typical figure; increase it if you read or scroll in bed.
- Pick your age group. The cards then say whether each option meets the guidance - for adults aged 18 to 60, at least seven hours.
- The highlighted card is the shortest option that still meets the guidance for your age. Earlier bedtimes give more cycles; later ones fewer.
- Press the alarm button to open the online alarm clock and set the time shown, or copy the list of times.
Reading the results
A bedtime here is when to be in bed with the light off, not when to start getting ready. The minutes to fall asleep are already included.
"Meets guidance" compares the hours of sleep in that option with the recommended range for the age group. An option that is "less than advised" now and then is not harmful in itself; regularly sleeping less than the guidance is what the recommendations warn against.
If you wake up before the alarm at the end of a cycle and feel alert, that is the rule of thumb working. If you still wake groggy, try shifting the cycle length in the advanced settings by 5-10 minutes for a week and see whether it suits you better.
Worked example: an adult who has to get up at 6:30
With 15 minutes to fall asleep and 90-minute cycles, going back from 6:30: five cycles is 7 hours 30 minutes of sleep, plus 15 minutes, so be in bed at 10:45 PM. Six cycles (9 hours) means 9:15 PM; four cycles (6 hours) means 12:15 AM; three cycles (4 hours 30 minutes) means 1:45 AM.
For an adult aged 18-60 the recommendation is seven hours or more, so 10:45 PM is the latest option that meets it and is highlighted. 12:15 AM gives only six hours and is marked as less than advised.
A teenager with the same alarm needs 8-10 hours, so the calculator highlights 9:15 PM (nine hours) instead.
Formulas and scoring rules
- Bedtime for a wake-up time
bedtime = wake time − (cycles × cycle length) − minutes to fall asleepShown for 6, 5, 4 and 3 cycles; times wrap past midnight.- Wake-up time for a bedtime
wake time = bedtime + minutes to fall asleep + cycles × cycle length- Hours of sleep
sleep = cycles × cycle lengthWith the default 90 minutes: 3 cycles = 4.5 h, 4 = 6 h, 5 = 7.5 h, 6 = 9 h. Time spent falling asleep is not counted as sleep.- Highlighted option
the shortest option within the age range; if none, the one closest to the minimum
How much sleep do you need by age?
Recommended sleep per 24 hours, from the AASM paediatric consensus (2016), the AASM and Sleep Research Society adult consensus (2015) and the National Sleep Foundation (2015), as listed by the CDC: newborns 0-3 months 14-17 hours; infants 4-12 months 12-16 hours; toddlers 1-2 years 11-14 hours; children 3-5 years 10-13 hours (all including naps); children 6-12 years 9-12 hours; teenagers 13-17 years 8-10 hours; adults 18-60 years 7 hours or more; adults 61-64 years 7-9 hours; adults 65 and over 7-8 hours.
These are ranges for healthy people. Illness, pregnancy, training load and sleep debt can raise what an individual needs for a while, and some people sit naturally at either end of the range.
What a sleep cycle is
During the night you move through light sleep, deep (slow-wave) sleep and REM sleep and back again, several times. One pass is a cycle. Early cycles carry more deep sleep and later ones more REM, and their length varies. Waking from deep sleep is more likely to leave you groggy - sleep inertia - which is the reason behind the advice to time the alarm for the end of a cycle. Because cycle length is not fixed, a consistent bedtime and wake time every day usually does more for how rested you feel than exact cycle arithmetic.
Limitations: what the result does not prove
- The cycle length is an average used as a rule of thumb. It does not measure your sleep, and no calculator can know which stage you are in at a given minute.
- It is not medical advice and cannot detect sleep disorders. Persistent insomnia, loud snoring, pauses in breathing or daytime sleepiness despite enough time in bed are reasons to see a doctor.
- For babies and young children the guidance includes naps, so a single night-time window will look shorter than the total.
- The "sleep now" option reads this device's clock. If the device's time zone is wrong, so are the suggested times.
Privacy: where your data goes
Everything you paste, type or drop is processed in this browser tab. It is not uploaded, logged, stored or sent to analytics. Session recording and tag-manager scripts are switched off on this page.
Standards and sources
- CDC - About Sleep: recommended hours of sleep by age
- Paruthi et al. (2016) - AASM consensus on recommended sleep for paediatric populations
- Watson et al. (2015) - AASM/SRS consensus on recommended sleep for healthy adults
- Hirshkowitz et al. (2015) - National Sleep Foundation sleep duration recommendations
- NHLBI (NIH) - How sleep works: sleep phases and stages
Frequently asked questions
What time should I go to bed if I wake up at 7 am?
With 15 minutes to fall asleep and 90-minute cycles, 11:15 PM gives five cycles (7.5 hours) and 9:45 PM gives six cycles (9 hours). 12:45 AM gives four cycles, which is six hours and below the seven hours recommended for adults.
How much sleep do I need for my age?
Adults aged 18 to 60 are advised to get at least seven hours, teenagers 8 to 10 hours, children aged 6 to 12 between 9 and 12 hours and adults 65 and over 7 to 8 hours. Choose your age group and each suggested time is checked against it.
Is a sleep cycle always 90 minutes long?
No. Ninety minutes is a convenient average; measured cycles range from about 80 to 120 minutes and change across the night. If the default times do not suit you, adjust the cycle length in the advanced settings.
Is it better to sleep 6 hours or 7.5 hours?
For adults, 7.5 hours meets the recommendation of seven or more and six does not. Waking at the end of a cycle may feel easier, but getting enough total sleep over the week matters more than hitting a cycle boundary.
Why does the calculator add 15 minutes?
Because most people do not fall asleep the moment they lie down. The time to fall asleep is added before the first cycle starts. Change it to match you; if you regularly take more than about 30 minutes, it is worth mentioning to a doctor.
Can I set an alarm from the sleep calculator?
Yes. The button under the results opens the a2z.tools online alarm clock, where you can set the time shown. Keep that browser tab open and the device awake for the alarm to sound.
Last reviewed by the A2Z.Tools team against the sources listed above.