All tools › Everyday Calculators › Date & Time
Find the hours and minutes between two clock times, with decimal hours and an optional break.
What the time duration calculator does
This time duration calculator tells you how long it is from one clock time to another. Enter a start time and an end time and it gives the span in hours and minutes, in decimal hours, in total minutes and in total seconds. You can also take off an unpaid break.
It is built for the everyday cases: a work shift for a timesheet, the length of a class or meeting, a flight or drive with known start and end times, or a night’s sleep. Shifts that run past midnight work too.
How to use the time duration calculator
- Set the Start time.
- Set the End time. If it is earlier on the clock than the start time, the tool treats it as the next day.
- Type any Unpaid break to subtract in minutes, or leave it at 0.
- Read the duration at the top and the decimal hours, total minutes and total seconds in the rows below.
How the duration is calculated
Both times are turned into seconds after midnight, then subtracted.
duration = end – start (+ 24 hours if end is before start) – break
- start and end are the two clock times.
- + 24 hours applies only when the end time is earlier on the clock than the start time, which means the span crosses midnight.
- break is the unpaid break in minutes. It cannot be negative or longer than the span.
Decimal hours are the duration in minutes divided by 60, shown to two decimal places. That is the number most payroll and billing systems ask for.
Worked examples
A day shift with a lunch break. Inputs used: Start time 8:45 AM, End time 5:15 PM, Unpaid break to subtract 30 minutes.
| Result | Value |
|---|---|
| Duration | 8 hours 0 minutes |
| Decimal hours | 8 |
| Total minutes | 480 |
| Total seconds | 28,800 |
| Span before the break | 8 h 30 min |
A night shift. Inputs used: Start time 10:00 PM, End time 6:30 AM, no break. The duration is 8 hours 30 minutes, or 8.5 decimal hours and 510 minutes, and the To row reads “6:30 AM the next day”.
Minutes that do not divide evenly. Inputs used: 9:00 AM to 4:40 PM, no break. The duration is 7 hours 40 minutes, 460 minutes, and 7.67 decimal hours.
Hours and minutes versus decimal hours
These two are easy to mix up. 7 hours 40 minutes is not 7.40 hours. Forty minutes is 40 ÷ 60 of an hour, which is 0.67, so the decimal figure is 7.67.
| Minutes | Decimal hours |
|---|---|
| 6 | 0.1 |
| 15 | 0.25 |
| 30 | 0.5 |
| 45 | 0.75 |
To work out pay by hand, multiply the decimal hours by the hourly rate, not the hours-and-minutes figure. Because the decimal value is rounded to two places, a payroll system that rounds differently, for example to the nearest quarter hour, can give a slightly different total.
What the calculator does not cover
- Spans of 24 hours or more. The tool has no date fields, so the longest span it can show is just under 24 hours. For longer periods, count the days separately.
- The same start and end time. This gives zero, not 24 hours.
- Time zones. Both times are assumed to be on the same clock. For a flight that lands in another zone, convert one of the times first.
- Clock changes. A night when clocks move forward or back by an hour is not adjusted for.
- Several shifts at once. It handles one span at a time; add the decimal hours of each day yourself for a weekly total.
- Overtime and paid breaks. Only the break you type is taken off. Pay rules are up to your employer and local law.
Frequently asked questions
How do I add up a whole week of shifts?
Calculate each day, write down the decimal hours for each one, and add those numbers. Decimal hours add up directly, while hours and minutes need carrying at 60.
Can I enter a break in hours?
The break field is in minutes. Type 60 for a one-hour break or 90 for an hour and a half.
Does it work with a 24-hour clock?
The time fields follow your device’s own clock format, so they may show AM and PM or 24-hour time. The result rows are written in AM and PM.
How do I measure my sleep?
Enter bedtime as the start time and wake-up time as the end time. Since the wake-up time is earlier on the clock, the tool counts it as the next morning.
Related calculators
- Date Calculator – count days between dates when the span is longer than a day.
- Age Calculator – time since a date in years, months and days.
- Pace Calculator – turn a run’s time and distance into pace.
- Unit Converter – convert between seconds, minutes, hours and days.
