Time Duration Calculator
Add or subtract two durations in hours, minutes and seconds, with decimal hour totals.
Draft — figures checked, awaiting an editorial read. Not indexed.
Formula: Convert both durations to seconds, add or subtract, then convert back to hours, minutes and seconds.
What this calculates
This adds or subtracts two durations expressed in hours, minutes and seconds, and gives the answer both in that same format and as decimal hours. The decimal output is the part people most often need, because time is recorded in hours and minutes but billed and paid in decimal hours — and 2 hours 45 minutes is 2.75 hours, not 2.45. That mismatch is the source of a surprising amount of payroll and invoicing error, and it always favours whoever made the mistake in one direction only.
How it works
Both durations are converted into a single number of seconds, which removes the base-60 problem entirely. The two totals are then added or subtracted as ordinary numbers. Converting back divides by 3,600 for whole hours, takes the remainder and divides by 60 for minutes, and leaves the seconds. Subtracting a larger duration from a smaller one gives a negative result, which is displayed as such rather than being clamped to zero — a negative difference is usually meaningful.
Worked example
Adding 2 h 45 m to 1 h 30 m: 2 × 3600 + 45 × 60 = 9,900 seconds, plus 1 × 3600 + 30 × 60 = 5,400 seconds, giving 15,300 seconds. Converting back: 15,300 ÷ 3,600 = 4 whole hours with 900 seconds left, which is 15 minutes. So 4 h 15 m, or 4.25 decimal hours. Note that adding the minute columns directly — 45 + 30 = 75 — is where people go wrong, since 75 minutes has to carry over into an hour.
Common mistakes
Treating minutes as decimals. Writing 2 hours 45 minutes as "2.45 hours" understates it by 18 minutes, and doing that across a week of timesheets adds up. Second, forgetting to carry when minutes exceed sixty. Third, subtracting across midnight without accounting for the day boundary — that is a clock-time problem rather than a duration problem, and it needs a date attached to be answerable.
Common questions
- How do I convert minutes to decimal hours?
- Divide by 60. Fifteen minutes is 0.25 hours, thirty is 0.5, forty-five is 0.75. The common error is writing 45 minutes as 0.45 hours, which is nearly twenty minutes short.
- Can it handle a negative result?
- Yes. Subtracting a longer duration from a shorter one returns a negative duration rather than zero, which is usually what you want when comparing an estimate against actual time spent.