Sleep Debt Snapshot
{{ debt_readable }}
{{ debtBandLabel }} across {{ dayCount }} night(s)
Need {{ formatFixed(sleepNeedValue, 2) }} h/night Avg {{ formatFixed(avg_hours, 2) }} h {{ debtBandLabel }} {{ shortSleepNights }} short nights {{ currentRecoveryLane.dayLabel }} Wake {{ wake_anchor }}
h/night
Recent nights
h
h
min
h
h
Debt band
{{ debtBandLabel }}
{{ formatFixed(net_debt, 2) }} h net debt under the current rules.
Shortfall pattern
{{ shortSleepNights }} short nights
Longest streak: {{ longestShortfallStreak }} nights below target.
Current lane
{{ currentRecoveryLane.label }}
{{ currentRecoveryLane.dayLabel }}, bedtime {{ currentRecoveryLane.bedtimeTarget }}
Metric Value Copy
{{ metric.label }} {{ metric.value }}
Night Slept Need Deficit Surplus Credit Net change Cum. debt Copy
{{ r.label }} {{ formatFixed(r.slept, 2) }} {{ formatFixed(r.need, 2) }} {{ formatFixed(r.deficit, 2) }} {{ formatFixed(r.surplus, 2) }} {{ formatFixed(r.creditApplied, 2) }} {{ formatSignedHours(r.netChange, 2) }} {{ formatFixed(r.cumDebt, 2) }}
Lane Night extra Nap Capacity Days Pace Bedtime target Note
{{ lane.label }}
{{ formatFixed(lane.nightExtra, 2) }} h {{ formatFixed(lane.napExtra, 2) }} h {{ formatFixed(lane.recoveryCapacity, 2) }} h {{ lane.isRecoverable ? formatFixed(lane.estimatedDays, 2) : 'Infinity' }} {{ lane.paceLabel }} {{ lane.bedtimeTarget || 'Set wake anchor' }} {{ lane.note }}
Day Night extra Nap extra Capacity Remaining debt
Day {{ r.day }} {{ formatFixed(r.nightExtra, 2) }} h {{ formatFixed(r.napExtra, 2) }} h {{ formatFixed(r.nightExtra + r.napExtra, 2) }} h {{ formatFixed(r.remaining, 2) }} h
{{ currentRecoveryLane.label }} {{ currentRecoveryPaceLabel }} {{ referenceRecoveryLane.label }}

                

Enter your nightly log to generate sleep debt metrics, recovery lanes, charts, and exports.

:

Introduction

Sleep debt is the running gap between the sleep you meant to get and the sleep you actually logged across recent nights. One short night can feel obvious on its own, but the more useful question is whether a whole stretch of late bedtimes, travel, deadlines, illness, or early alarms is still dragging behind you.

This calculator turns that question into a concrete ledger. You set a nightly sleep target, choose a 7-night or 14-night horizon, enter recent sleep, and decide how strict the accounting should be. Optional rules let you round entries to a minute block, cap the damage from one very short night, and decide whether longer nights can pay back earlier loss. The result is shown as a net sleep debt, a tool-specific debt band, a night-by-night ledger, a catch-up schedule, a debt timeline, and a recovery pace map.

Sleep target manual or guide 9.0 / 8.0 / 7.5 h Recent nights 7 or 14 nights round / cap / credit Running debt gross deficit minus allowed credit Recovery view lanes, days, bedtime target One set of nightly entries drives every result surface. Snapshot, Night Ledger, Recovery Lanes, Debt Timeline, Recovery Pace, and JSON all come from the same sleep log.
The page does not just show one debt number. It keeps the assumptions, the running balance, and the recovery plan visible together.

The built-in sleep-need guides are starting points, not diagnoses. The teen guide loads 9 hours, the adult guide loads 8 hours, and the older-adult guide loads 7.5 hours. Those defaults sit near the middle of widely used public sleep-duration guidance, which makes them useful when you need a baseline but do not want to guess wildly.

The calculation stays in the browser unless you choose to copy or download results. That helps with private tracking, but exported files can still contain your nightly pattern and recovery assumptions. The tool also cannot tell why sleep was short. Snoring with breathing pauses, long-term insomnia, persistent daytime sleepiness, or work schedules that repeatedly fight your body clock need more context than a debt estimate can provide.

Technical Details

The calculator reads the selected nights from oldest to newest, not newest to oldest. That detail matters because oversleep credit can only erase debt that already exists. A longer night late in the week can pay down an earlier deficit, but it cannot create a negative debt balance or grant extra credit beyond zero.

Each night goes through the same sequence: optional rounding, deficit calculation, optional surplus credit, and then a running cumulative balance.

Pi = processed sleep for night i after optional rounding Di = max(0,Need-Pi) Di with cap = min(Di,Cap) when the cap is above zero Ci = min(Surplus,Runningi-1+Di) when credit is on Runningi = max(0,Runningi-1+Di-Ci) Catch-up days = Net debtNight extra+Nap allowance when daily recovery capacity is above zero
Built-in sleep-need guides compared with common public sleep guidance
Guide loaded here Baseline Public sleep context How to use it
Teen guide (14-17 years) 9.0 h/night Public guidance commonly places teens around 8 to 10 hours. A midpoint starting point when the user needs a reasonable baseline.
Adult guide (18-64 years) 8.0 h/night Public guidance commonly says most adults need at least 7 hours, with 7 to 9 hours often used as a normal range. A practical default for scenario testing, not a personal prescription.
Older adult guide (65+ years) 7.5 h/night Public guidance commonly places adults 65 and older around 7 to 8 hours, even though sleep may become lighter or more fragmented. A midpoint default when older-adult sleep is being reviewed.
Debt bands and recovery pace labels used by the calculator
Label shown here Trigger Meaning on this page
Debt clear ≤ 0.01 h The running balance has been cleared under the current rules and horizon.
Minimal debt > 0.01 h and < 1 h A very small recent shortfall remains.
Low debt 1 h to < 3 h A mild running deficit remains.
Moderate debt 3 h to 5 h The recent shortfall is large enough to deserve deliberate recovery planning.
High debt > 5 h The selected horizon still contains a large unmet sleep gap.
No recovery lane Positive debt and 0 h/day capacity The current settings do not provide any extra sleep or nap time to clear the balance.
Quick recovery Estimated clearance in 3 days or less The current plan would clear the balance quickly if the extra sleep really happens.
Steady recovery More than 3 days and up to 7 days The plan is workable, but it is not especially fast.
Long recovery More than 7 days The plan pays the debt down slowly under the current assumptions.

The Recovery Lanes tab shows one lane built from your own settings plus three built-in comparison lanes. Gentle reset assumes 0.25 extra hours of night sleep and no nap. Steady reset assumes 0.50 extra hours at night plus a 0.33-hour nap. Aggressive reset assumes 1.00 extra hour at night plus a 0.33-hour nap. If you provide a wake anchor, each lane also converts the sleep target plus planned night extra into a bedtime target.

The exports mirror what you see on screen. Snapshot, Night Ledger, and Recovery Lanes can be copied or downloaded as CSV and DOCX. Debt Timeline and Recovery Pace can be exported as PNG, WebP, JPEG, or CSV. The JSON view bundles inputs, totals, insights, daily rows, recovery lanes, and the generated catch-up plan. The current implementation performs those calculations locally and does not rely on a server-side helper for routine use.

Everyday Use & Decision Guide

Start with the sleep target, because every other number depends on it. If you already know the person usually functions best near 7.5, 8, or 9 hours, enter that value directly. If you do not know, use one of the built-in guides as a midpoint and then adjust only after looking at the rest of the picture. Repeatedly changing the target between runs makes the debt number harder to compare over time.

The horizon decides how quickly older nights disappear. A 7-night view is better for a recent workweek, a travel stretch, or a short illness. A 14-night view is better when you want to see whether last weekend's recovery still matters or whether short sleep has been repeating for two full weeks. Neither horizon is more correct in general. They answer slightly different questions.

Oversleep credit is the setting that changes interpretation the most. Turn it on when you want the calculator to treat longer nights as practical payback against earlier loss. Turn it off when you want a stricter record of shortfall only. People often compare these two views side by side because the difference shows how much of the current debt depends on the assumption that rebound sleep really counts as repayment.

Use the nightly deficit cap and the rounding rule only when they solve a specific problem. A cap is useful if one extreme night would otherwise dominate the whole horizon and make the summary less useful for planning. Rounding is helpful when your log is approximate and you want entries to land on a consistent minute block. If your sleep record is precise enough already, leaving both off keeps the ledger closest to the raw numbers.

The recovery settings are planning assumptions, not promises. Max extra per day and nap allowance define how much additional sleep you think is realistically available. If you can shift bedtime but cannot nap, say so. If naps are possible but short, keep the number modest. Adding a wake anchor is especially useful when you already know the time you must get up, because the tool can then translate each lane into a bedtime instead of leaving recovery as an abstract number of hours.

Step-by-Step Guide

  1. Choose a preset if you want a quick sample log, or leave the page on Custom and enter your own recent nights.
  2. Set the nightly sleep target directly, or load the teen, adult, or older-adult guide as a starting point.
  3. Pick a 7-night or 14-night horizon, then enter the selected nights from the most recent backward.
  4. Open Advanced only if you need to change how the ledger behaves: oversleep credit, deficit cap, rounding, wake anchor, extra sleep, or nap allowance.
  5. Read Snapshot first so you can see gross deficit, credit applied, net debt, the debt band, and the current recovery headline in one place.
  6. Open Night Ledger, Recovery Lanes, Debt Timeline, Recovery Pace, or JSON only after the assumptions look realistic enough to keep for planning or export.

Interpreting Results

The most useful reading starts with three numbers together, not one. Gross deficit tells you how much sleep was lost before any payback is counted. Oversleep credit applied tells you how much longer nights erased under the current rule set. Net sleep debt is the balance that remains. If net debt looks surprisingly low, check whether longer nights, a shorter horizon, or a deficit cap are doing most of the work.

The debt band is a tool label, not a medical grade. It is there to make the headline easier to scan and to anchor the recovery map, but the actual hours matter more than the badge color. A 0.9-hour balance and a 1.1-hour balance fall into different labels even though they may feel similar in real life. That is normal when a calculator turns a continuous number into named buckets.

The Night Ledger shows how the balance formed. A steady run of mild short nights usually points to a habit problem or schedule squeeze. One sharp jump followed by longer nights points to an isolated disruption and partial recovery. The Debt Timeline turns that same pattern into a quick visual check. If the orange line is still climbing late in the horizon, the situation is still worsening. If it is flattening or falling, recovery has already started under the current rules.

The Recovery Lanes and Recovery Pace views answer a different question: how quickly the current debt would clear if your extra sleep plan actually happens. A positive result there does not prove full biological recovery. Extra sleep and naps can help alertness and reduce some short-term sleepiness, but public sleep guidance still treats repeated short sleep as a health and safety problem in its own right. The recovery schedule is best read as a practical rest plan, not as proof that every consequence of inadequate sleep has been erased.

A zero balance also needs context. It means the selected nights, under the selected rules, no longer show a remaining running debt. It does not prove that the person never had a problem, that older missed sleep outside the chosen horizon is irrelevant, or that daytime symptoms must have another cause.

Worked Examples

A busy week that ends with two longer nights

Suppose the target is 8 hours and the week's seven nights are 6.0, 6.5, 7.0, 7.5, 8.0, 8.5, and 8.5 hours. Gross deficit is 5.0 hours. The two longer nights contribute 1.0 hour of oversleep credit, so net sleep debt ends at 4.0 hours. If the current plan allows 1.5 extra hours at night and a 0.5-hour nap per day, the tool estimates about 2 days to clear that balance.

The same log with stricter accounting

Run the same week again with oversleep credit turned off. Gross deficit stays at 5.0 hours, but credit applied falls to 0.0, so net sleep debt stays at 5.0 hours. Nothing about the sleep log changed. Only the accounting rule changed. That is why comparing credit-on and credit-off runs is often the fastest way to see how much of the apparent recovery comes from one assumption.

One extreme night with a deficit cap

Now imagine a target of 8 hours and one unusually short 3.5-hour night during an otherwise ordinary week. Without a cap, that night adds 4.5 hours of deficit by itself. With a 2.0-hour cap, the same night adds only 2.0 hours to the running debt. The capped version can be more useful when you are building a practical catch-up plan and do not want one crisis night to dominate the whole summary.

FAQ

Can one weekend of longer sleep erase a week's debt?

Sometimes it reduces the number a lot, especially if oversleep credit is on and the longer nights are inside the chosen horizon. That still does not guarantee full recovery from repeated insufficient sleep. The tool is showing the balance under your selected rules, not promising that every effect of sleep loss is gone.

Why do the 7-night and 14-night views disagree?

Because they are looking at different windows. The 7-night view forgets older nights sooner. The 14-night view keeps earlier short sleep or earlier rebound sleep in the ledger longer.

Why does the bedtime target move so early when I add recovery sleep?

The bedtime target subtracts both the regular sleep need and the extra planned night sleep from your wake anchor. If your wake time is fixed, adding a full extra hour for recovery pushes bedtime earlier by a full extra hour as well.

When should this result lead to a medical conversation?

Seek medical advice if sleep is regularly short despite enough time in bed, if you feel very sleepy during the day, if someone notices loud snoring or pauses in breathing, or if shift work and schedule changes keep making sleep unmanageable. Those patterns may point to more than a scheduling problem.

Glossary

Sleep need
The nightly target in hours that every deficit and recovery calculation uses as its baseline.
Gross deficit
The total shortfall accumulated before any longer nights are allowed to pay it back.
Oversleep credit
The amount of sleep above target that the calculator is allowed to apply against an existing running balance.
Horizon
The number of recent nights included in the current ledger, either 7 or 14.
Recovery capacity
The extra sleep and nap time per day that the calculator assumes is available for catch-up.
Wake anchor
A chosen wake time that lets the page convert each recovery lane into a bedtime target.