How to Calculate Hours Between Two Times
Work out the hours between two clock times, including breaks and shifts that cross midnight, and convert to decimal hours.
By Editorial Team · Updated September 19, 2026 · 1 min read
Subtracting clock times looks easy until minutes run past 60 or a shift crosses midnight. This guide shows a reliable method for both.
Same-day shifts
Convert each time to minutes since midnight, subtract, and convert back.
A shift runs from 9:15 to 17:45.
- 9:15 is 9 × 60 + 15 = 555 minutes
- 17:45 is 17 × 60 + 45 = 1,065 minutes
- Difference: 1,065 − 555 = 510 minutes, which is 8 hours 30 minutes
Deducting a break
Subtract unpaid break time from the total. With a 30-minute break, 8 hours 30 minutes becomes 8 hours.
Overnight shifts
If the end time is earlier than the start time, the shift ends on the next day, so add 24 hours (1,440 minutes) to the end time.
Minutes worked = (end − start) + 1,440 if end < startA shift from 22:00 to 06:30: 06:30 is 390 minutes and 22:00 is 1,320. The difference is 390 − 1,320 = −930, and adding 1,440 gives 510 minutes, so 8 hours 30 minutes.
Converting to decimal hours
Payroll systems usually want decimal hours. Divide the minutes by 60.
| Time | Decimal hours |
|---|---|
| 7 h 15 min | 7.25 |
| 7 h 30 min | 7.50 |
| 7 h 45 min | 7.75 |
| 8 h 10 min | 8.17 (8.1667) |
Common mistakes
- Writing 7 hours 45 minutes as 7.45. Minutes are out of 60, not 100.
- Forgetting that a shift crosses midnight.
- Leaving out the unpaid break.
The hours calculator does all of this from a start time, an end time and a break.
Try it yourself
- A shift runs from 8:20 to 16:50 with a 45-minute unpaid break. How many hours is that in decimal form?
- How long is a shift from 23:15 to 07:00?
- Write 40 minutes as decimal hours.
Answers: (1) 7.75 hours (510 − 45 = 465 minutes); (2) 7 hours 45 minutes, or 7.75 hours; (3) 0.67 hours (40 ÷ 60 = 0.667).
Frequently asked questions
- How do I calculate hours worked with a lunch break?
- Subtract start from end, then take away the break. 9:00 to 17:30 with 30 minutes off is 8 hours.
- How do I convert 8 hours 20 minutes to decimal?
- Divide 20 by 60, which is 0.333, and add 8. The result is 8.33 hours.
- What if the end time is earlier than the start time?
- Treat the end as the next day by adding 24 hours before subtracting.
About the author
Editorial Team. The Editorial Team writes, checks and maintains every tool and guide on this site. The calculation logic behind the calculators is covered by automated tests, examples are worked out and re-checked before publishing, and pages are updated when we find a mistake or a rule changes. Corrections are welcome through the contact page.
Tools mentioned in this guide
- Hours CalculatorFind the hours and minutes between two clock times, with an optional unpaid break.
- Time CalculatorAdd and subtract durations in hours, minutes and seconds.
- Work Hours CalculatorAdd up a week of shifts with breaks. Get total hours, overtime against a target and optional gross pay.
- Meeting Time PlannerConvert one meeting time across several time zones and see who is inside working hours.
- Percentage CalculatorFind X% of a number, what percent one number is of another, or the total behind a percentage.
- Percentage Increase CalculatorFind the percentage increase between two numbers, or raise a number by a percentage.