=Calculator Hub

Time Duration Calculator (Hours Between Two Times)

Enter a start time and end time to see exactly how long the shift lasted, in hours and minutes and as decimal hours for payroll. Subtract an unpaid lunch or break, and overnight shifts that cross midnight are handled automatically.

min
Time worked7h 30m
Decimal hours7.5 h
Total minutes450 min

How this calculation works

Both times are read as clock times (HH:MM, 24-hour). The calculator converts each to minutes since midnight, then subtracts start from end to get the raw span worked.

If the end time is earlier than the start time (for example 22:00 to 06:00), the calculator assumes the shift crosses midnight and adds 24 hours to the end time before subtracting — no need to enter a separate date.

Your unpaid break in minutes is subtracted from that raw span to get net time worked. The result is shown as hours and minutes (e.g. 7h 30m) and as decimal hours (7.5) for payroll systems that need a single number.

Worked example

A shift starts at 09:00 and ends at 17:30, with a 60-minute unpaid lunch. Raw span is 8h 30m (510 minutes); minus the 60-minute break leaves 450 minutes, shown as 7h 30m and 7.5 decimal hours.

Converting minutes to decimal hours

Payroll software needs a single decimal number, not "hours and minutes". To convert manually, divide the minutes by 60. Some common conversions:

MinutesDecimal hours
15 min0.25 h
30 min0.50 h
45 min0.75 h
7h 15m (435 min)7.25 h
7h 30m (450 min)7.50 h
7h 45m (465 min)7.75 h

Handling overnight and split shifts

Shift workers, security staff, and hospitality employees often clock in before midnight and out after it. Enter the times exactly as they appear on the clock — the calculator detects that the end time is numerically earlier than the start time and automatically rolls it into the next day, so a 23:00–07:00 shift correctly returns 8 hours rather than a negative number.

For a split shift (worked in two separate blocks with an unpaid gap between them, rather than a single continuous break), calculate each block separately with this tool and add the two decimal-hour results together.

Why unpaid breaks matter for compliance

Frequently asked questions

How do I enter an overnight shift?
Just enter the clock times as normal, e.g. start 22:00 and end 06:00. Because the end time is earlier than the start time, the calculator automatically treats it as crossing midnight and adds 24 hours before subtracting, so you get the correct 8-hour span.
What format should I use for the times?
24-hour HH:MM, such as 09:00 for 9 AM or 17:30 for 5:30 PM. Using 24-hour format avoids AM/PM mix-ups, especially for shifts that run late into the evening.
Why does decimal hours matter for payroll?
Most payroll and timesheet systems store hours as a decimal number rather than hours-and-minutes, because it's easier to multiply by an hourly rate. 7 hours 30 minutes becomes 7.5 decimal hours; 7 hours 15 minutes becomes 7.25, not 7.15.
What if I don't take a break?
Set the break minutes to 0. The full span between start and end time will be counted as time worked.
What happens if my break is longer than the shift?
The result is floored at zero hours rather than going negative — if you enter a break longer than the raw span between start and end, the calculator shows 0h 00m instead of a negative duration.
Does this calculator store my times?
No. Everything runs locally in your browser; no start time, end time, or break is sent to a server or saved anywhere.
Can I use this for multiple breaks in one shift?
Yes — just add up all your unpaid break minutes (e.g. a 30-minute lunch plus two 15-minute breaks = 60 minutes) and enter the total in the break field.
This tool is provided for general information only. Verify important figures independently. · Last reviewed: August 25, 2026