To calculate the hours between two times, subtract the start time from the end time. If the end time is earlier than the start, the period ran past midnight, so add 24 hours before subtracting. The time duration calculator does this for you and shows the result in hours and minutes, in total minutes, and in decimal hours.
The basic subtraction
For a span within a single day, convert both times to a count from midnight and subtract. A shift from 09:00 to 17:30 is eight and a half hours, because 17:30 is 8 hours and 30 minutes after 09:00. Working in minutes first and then converting back to hours and minutes avoids slips with the 60-minute boundary.
Handling overnight shifts
The catch is a period that crosses midnight, where the end time on the clock looks earlier than the start. A shift from 22:00 to 06:00 is not negative, it is eight hours. The fix is to add a full day, 24 hours, to the end time before subtracting. The time duration calculator assumes any end time earlier than the start belongs to the next day, so overnight shifts come out right without extra steps.
Getting decimal hours
Hours and minutes are easy to read, but timesheets and invoices often want a single decimal number. To convert, divide the minutes by 60 and add them to the hours. So 8 hours 30 minutes becomes 8.5, and 1 hour 15 minutes becomes 1.25. This decimal figure multiplies straight by an hourly rate. The calculator shows it next to the hours and minutes.
Where this comes up
A clean hours-between figure matters for a few everyday tasks:
- Pay and timesheets, counting hours worked between clock-in and clock-out, including overnight shifts.
- Billing, turning a session into decimal hours for an invoice.
- Planning, measuring how long something took between a start and an end time.
Enter a start and end time in the time duration calculator to get the hours, minutes and decimal total at once. For spans across days rather than within one, see how many days between two dates.