Time Duration Calculator
Calculate elapsed date/time differences, overnight shifts or a date/time after adding or subtracting a duration. Deduct breaks and copy the result.
Estimated Result
Enter values and calculate.
Clear controls
Review inputs and results
Transparent methods
Understand the output
Works on any device
Mobile, tablet or desktop
How to Use the Time Duration Calculator
Choose date/time difference, time-only shift, add duration or subtract duration. Enter the relevant start/end values. Elapsed modes allow a break deduction; add/subtract modes use duration days, hours and minutes. Choose 24-hour or 12-hour result display. All values use UTC or the same explicitly entered fixed UTC offset, with no automatic daylight-saving adjustment.
Formula and Explanation
Elapsed minutes = (end timestamp − start timestamp) / 60,000 Time-only: add 24 hours when end time is earlier than start Net minutes = elapsed minutes − break minutes Decimal hours = net minutes / 60 Calendar-day difference = difference between civil date midnights New timestamp = start timestamp ± duration minutes × 60,000
Date/time values are interpreted in a fixed-offset civil time system, never the browser’s local timezone. UTC is the default; an offset such as +420 minutes labels both endpoints UTC+07:00. No regional daylight-saving rule is inferred. Elapsed duration measures hours/minutes, while calendar-day difference counts midnight boundaries before break deduction. Equal time-only endpoints mean zero hours, not a 24-hour shift.
Fixed UTC offsets do not model daylight-saving transitions or named regional timezones. For a shift crossing an offset change, convert both endpoints to UTC outside this tool before entering them. It does not model leap seconds, payroll rules or business-day calendars. Date inputs support years 0001–9999 and minute precision; fractional duration or break minutes may produce seconds in results. A break cannot exceed elapsed time.
Worked Example
An overnight shift from 22:00 to 06:00 spans 480 minutes. Deduct a 30-minute break to get 450 minutes, 7.5 decimal hours. From 2024-02-28 12:00 to 2024-03-01 12:00 in UTC is 48 hours because 2024 has February 29. Adding 90 minutes to 2025-01-31 23:30 gives 2025-02-01 01:00.
Frequently Asked Questions
Will daylight-saving changes be handled automatically?
No. Both endpoints use UTC or one fixed offset. To measure an interval crossing a daylight-saving change, first convert its actual endpoints to UTC. The tool does not silently use the browser’s timezone.
How does an overnight time-only shift work?
If the end clock time is earlier than the start, the end is treated as the next day. Equal clock times mean zero duration. Use date/time mode for intervals of 24 hours or longer.
Why can calendar days differ from elapsed days?
Calendar-day difference counts midnight boundaries between the dates. A two-hour interval from 23:00 to 01:00 crosses one calendar day but is only two elapsed hours. Break deduction changes elapsed totals, not those date boundaries.
Can breaks or subtraction make the result invalid?
A break larger than the elapsed interval is rejected. Subtracting a duration from a date is supported, but its resulting date must stay within years 0001–9999. Add/subtract mode does not also deduct breaks.
Related Tools
Electricity Cost Calculator · Unit Conversion Calculator · Time Zone Converter · Browse all tools