Time Duration Calculator
Find how long it is from one time to another, for a work shift, a journey or a recording. It handles shifts that cross midnight, spans of several days when you add dates, and an unpaid break that is taken off the total.
Leave both dates empty for two times on the same day.
Subtracted from the total, for timesheets.
Result
Enter a start time and an end time.
The calculation runs in this browser tab. Nothing you enter is uploaded, saved or logged.
How is the duration between two times calculated?
A duration is the end time minus the start time. Between 09:00 and 17:30 it is 8 hours 30 minutes. It becomes less straightforward when the end is earlier on the clock than the start: a shift from 22:00 to 06:15 crosses midnight, and the end belongs to the next day, so the duration is 8 hours 15 minutes.
When no dates are given the calculator assumes the span is under 24 hours and treats an earlier end time as the next day. For anything longer, enter the start and end dates as well and the span is measured exactly, to the day, hour and minute. For timesheets, the result is also given in decimal hours, where 7 hours 45 minutes is 7.75.
How to use the Time Duration Calculator
- Enter the start time and the end time. For longer spans, also enter both dates.
- Optionally enter an unpaid break in minutes. It is subtracted from the total.
- Read the duration in words, then as hours:minutes:seconds, as decimal hours, in total minutes and in total seconds.
- Use Copy result to copy the duration, or Reset to start again.
Formula
- Same day
- duration = end time − start time
- Across midnight (no dates)
- duration = end time − start time + 24 hours, when the end is earlier than the start
- With dates
- duration = days between × 24 hours + end time − start time
- Decimal hours
- hours = minutes ÷ 60, so 45 minutes = 0.75 hours
A break reduces the net duration only: the page also shows the duration before the break.
Decimal hours that do not end, such as 20 minutes = 0.333… hours, are rounded to 6 decimals and marked ≈.
Worked example
A night shift from 22:00 to 06:15 with a 30-minute unpaid break. These are the results the calculator gives:
| Question | Result |
|---|---|
| Input: Start time | 22:00 |
| Input: End time | 06:15 |
| Input: Unpaid break (minutes, optional) | 30 |
| Duration after the break | 7 hours 45 minutes |
| Hours and minutes | 7:45:00 |
| Decimal hours | 7.75 |
| Total minutes | 465 |
| Total seconds | 27,900 |
| Before the break | 8 hours 15 minutes |
Assumptions and limits
- Times are plain clock times. Time zones and daylight-saving changes are not applied, so a span across a clock change can be an hour longer or shorter in reality.
- Without dates, spans of 24 hours or more cannot be expressed; two identical times give a duration of zero. Add dates to measure longer periods.
- If you enter dates, you must enter both; the end must not be before the start.
- The unpaid break is a whole number of minutes, up to 1,440, and cannot be longer than the period itself.
- Employers and payroll systems often round times to the nearest 5, 10 or 15 minutes; this calculator does not round.
Frequently asked questions
How do I calculate the hours between two times?
Subtract the start time from the end time. From 09:00 to 17:30: 17:30 − 09:00 = 8 hours 30 minutes. If the end is earlier on the clock, add 24 hours, because it is on the next day.
How do I calculate hours worked with a lunch break?
Work out the time between clocking in and out, then subtract the unpaid break. From 09:00 to 17:30 with 30 minutes unpaid is 8 hours. Enter the break in the dedicated field and the calculator does it for you.
How do I convert hours and minutes to decimal hours?
Divide the minutes by 60 and add them to the hours. 7 hours 45 minutes is 7 + 45 ÷ 60 = 7.75 hours. The calculator shows this as “Decimal hours”.
How does the calculator handle shifts that cross midnight?
If the end time is earlier than the start time and no dates are entered, it assumes the end is the next day and says so. For 22:00 to 06:15 the duration is 8 hours 15 minutes.
Can I measure more than 24 hours?
Yes: enter the start and end dates as well as the times. 20 June 09:00 to 22 June 10:30 is 2 days 1 hour 30 minutes, shown as 49:30:00 in hours.
Why does the result sometimes show ≈?
Decimal hours for a period such as 20 minutes (0.333… hours) have no exact decimal form, so they are rounded. The hours, minutes and seconds shown elsewhere are exact.