Sleep Calculator

Runs locallyInput stays in your browserFree, no sign-up

Getting enough hours is only half the story — waking up at the end of a sleep cycle matters just as much. An adult sleep cycle lasts about 90 minutes, moving through light sleep, deep sleep and REM sleep in turn. An alarm that cuts into deep sleep leaves you groggy; waking at a cycle boundary feels noticeably easier. This calculator works from one simple formula: bedtime = wake-up time − cycles × 90 minutes − a 15-minute allowance to fall asleep, and wake-up time = bedtime + cycles × 90 minutes + 15 minutes. The 15 minutes is the average time it takes to drift off after getting into bed — cycles count from sleep onset, not from the moment you lie down.

Three scenarios cover most visits. First, you must be up at 7:00: enter it and the calculator returns four bedtimes — 11:15 PM for five full cycles, or 9:45 PM for six — which fits your body's rhythm better than a flat “eight hours” rule. Second, you plan to sleep at 11:00 PM: enter that and you get four wake-up points — 3:45 AM, 5:15 AM, 6:45 AM and 8:15 AM — so you can pick the one closest to your alarm and wake up less miserable. Third, after a late night you can only afford four and a half hours: rather than setting an alarm that slices through deep sleep, work backwards from three full cycles, because even a short sleep feels better when it ends at a cycle boundary.

A few edge cases deserve honesty. First, 90 minutes is an average — real cycles run roughly 80 to 120 minutes and vary from person to person, so these are reference slots, not a medical diagnosis. Chronic insomnia, heavy snoring or constant daytime sleepiness call for a sleep clinic, not a different alarm time. Second, the 15-minute falling-asleep allowance is also an average: scrolling your phone, caffeine or a bright room will stretch it, so leave some slack around the computed times. Third, overnight math wraps across midnight: with a midnight wake-up time, three cycles point to 7:15 PM the previous evening, and each table is labelled night-before or next-morning so the date is not misread. Fourth, naps and shift work can use the same math, but daytime sleep cycles are structured differently from night sleep, so the benefit is weaker. Fifth, teenagers and older adults need different total sleep than working-age adults — still start from five to six cycles and adjust by how you actually feel.

Using it is straightforward: the two inputs at the top take a wake-up time and a bedtime, and both result tables compute at once, each with four slots for three, four, five and six cycles, with the five-cycle slot marked recommended. Tap “Sleeping now” to set bedtime to the current time and get tonight's wake-up slots instantly; “Copy result” sends the most recently computed set to a message or a note; “Clear” resets both inputs. Everything runs locally in your browser — nothing is uploaded.

How to use

  1. Enter the time you want to wake up and the calculator returns bedtimes for three, four, five and six cycles; enter a bedtime and it works the other way, returning four wake-up times.
  2. Prefer the five-cycle slot — seven and a half hours of sleep. If time is short, four full cycles still beat six hours cut short in the middle of deep sleep.
  3. Tap “Sleeping now” to set bedtime to right now and get tonight's wake-up slots at once; “Copy result” sends the times to a message or a note.
  4. Set your alarm to the computed time, put the phone down half an hour before bed and dim the lights — the 15-minute falling-asleep allowance only holds if you actually wind down.

FAQ

Why 90 minutes per cycle?

That is the average structure of adult sleep: one cycle moves through light sleep, deep sleep and REM sleep in about 90 minutes, and a typical night runs four to six cycles. Deep-sleep interruptions feel the worst, while cycle boundaries feel easiest to wake from — so the calculator works backwards in whole cycles instead of simply subtracting eight hours.

Why add 15 minutes to fall asleep?

Because cycles count from sleep onset, not from lying down. Healthy adults take about 15 minutes on average to fall asleep after getting into bed — the sleep latency. The calculator builds that in: for a 7:00 wake-up with five cycles, the 11:15 PM bedtime means asleep by 11:15 PM, not in bed by 11:15 PM.

How many cycles are best?

Adults usually need five to six cycles a night — seven and a half to nine hours — and the calculator marks five cycles as recommended. If you must sleep short, protect whole cycles: four complete cycles feel better than five hours interrupted mid-deep-sleep. Consistently under four cycles a night is a schedule or health problem that an alarm tweak cannot fix.

Is everyone's cycle exactly 90 minutes?

No. Ninety minutes is an average; real cycles run roughly 80 to 120 minutes, and early-night cycles differ in length from late-night ones. Treat the slots as a starting point: if you still wake groggy after several days on the same slot, shift your alarm 15 to 20 minutes either way for a few days until you find your own rhythm.

Is my input uploaded anywhere?

No. Every calculation on this page runs locally in your browser. The times you enter never touch a server, are never recorded, and vanish when you close the page. It works offline too.