Enter the time you went to bed and the time you woke up into the calculator to estimate the elapsed time between them (time in bed).
Medical note: This calculator estimates elapsed time in bed from clock times and is for educational purposes only (not medical advice or a diagnosis). If you have persistent insomnia, loud snoring, witnessed breathing pauses, or excessive daytime sleepiness, consider speaking with a clinician.
Related Calculators
- Calories Burned Lying Down Calculator
- Rer (Resting Energy Requirement) Calculator
- BMI Calculator
- Weight Loss Percentage Calculator
- All Health and Medical Calculators
Time in Bed (Elapsed Time) Formula
The following formula is used to calculate the elapsed time (time in bed) based on the time you went to bed and the time you woke up.
T = (W - B + 24) % 24
Variables:
- T is the time in bed (elapsed hours)
- W is the time you woke up (24-hour time)
- B is the time you went to bed (24-hour time)
To calculate time in bed, subtract the time you went to bed from the time you woke up. If the result is negative, add 24 to account for sleeping past midnight. The modulo operation keeps the result within a 24-hour range.
What is Time in Bed?
Time in bed is the elapsed clock time between when you go to bed and when you wake up. It is not always the same as true sleep duration, because it does not account for how long it takes you to fall asleep or time spent awake during the night. Most adults need at least 7 hours of sleep per night, though some people may need more; for age-specific sleep recommendations, check guidance from major public health authorities (for example, the CDC or NIH).
How to Calculate Time in Bed?
The following steps outline how to calculate the time in bed.
- First, determine the time you went to bed (B) in 24-hour time.
- Next, determine the time you woke up (W) in 24-hour time.
- Calculate the time in bed using the formula T = (W – B + 24) % 24.
- Finally, check your answer with the calculator above.
Example Problem :
Use the following variables as an example problem to test your knowledge.
Time Went to Bed (B) = 22:00 (10:00 PM)
Time Woke Up (W) = 06:00 (6:00 AM)
