Date & Time100% FreeNo Sign-UpNo Tracking

Optimal Bedtime / Sleep Calculator

Find the ideal bedtime or wake-up time using sleep-cycle math.

Optimal Bedtime / Sleep Calculator Runs locally
Enter your values and press Calculate.

All calculations happen locally in your browser — nothing is uploaded, stored or tracked.

STEP 01

Pick a direction

Bedtime from wake time, or wake time from bedtime.

STEP 02

Enter your anchor time

When you must wake up, or when you plan to sleep.

STEP 03

Choose cycle count

4–6 cycles, and read the recommended times.

What Is a Sleep Calculator?

Sleep runs in cycles of roughly 90 minutes. Waking up at the end of a cycle — rather than mid-cycle — leaves you feeling more rested, because you are not interrupting deep sleep. This calculator works backwards from your target wake time to suggest bedtimes that complete whole cycles, including time to fall asleep.

It also works forwards: enter your bedtime and it shows wake times that complete 4 to 6 full cycles.

The Method

Bedtime = wake time − (cycles × 90 min) − 15 min (fall-asleep buffer)

Sleep needs vary: most adults feel best with 7–9 hours (roughly 5–6 cycles), teenagers often need 8–10 hours, and children more. The calculator offers 4, 5 and 6-cycle options so you can pick what matches your needs.

Limitations

Cycle length varies between people and nights. The calculator is a planning aid based on the common 90-minute average — it is not medical advice.

Your data never leaves your device.

Every calculation on this site runs in your browser using vanilla JavaScript. Nothing is uploaded, stored or tracked.

  • 100% local, client-side calculations
  • No data stored on any server
  • No tracking, no analytics, no ads scripts
  • Works offline once loaded

Frequently Asked Questions

What is the best time to go to bed?

A time that lets you complete whole 90-minute sleep cycles before your alarm. The calculator suggests bedtimes for 4, 5 and 6 cycles.

How many sleep cycles do adults need?

Most adults need 7–9 hours, which is about 5–6 cycles. Consistency matters more than any single night.

Why 90 minutes?

It is the average length of a full sleep cycle (light, deep and REM sleep). Waking between cycles feels better than waking mid-cycle.

Does the fall-asleep buffer matter?

Yes — most people take 10–20 minutes to fall asleep. The calculator adds a 15-minute buffer so your sleep start aligns with the cycle.

Can I use this for shift work?

It can suggest cycle-aligned sleep windows, but irregular schedules make consistency harder — adjust the anchor time to your actual sleep opportunity.