Find the exact duration between two times — hours, minutes and seconds. Works for overnight shifts, AM/PM, and 24-hour format.
⏱
Time Difference
How long between two times?
Select "Yes" for night shifts or any shift that crosses midnight.
—
—
Hours
—
Total minutes
—
Total seconds
➕
Add Time
What time will it be after adding hours and minutes?
Hours
Minutes
—
➖
Subtract Time
What time was it before subtracting hours and minutes?
Hours
Minutes
—
Ad — AdSense goes here
⚡ Common time durations — quick reference
From
To
Duration
9:00 AM
5:00 PM
8 hours
9:00 AM
5:30 PM
8 hours 30 min
8:00 AM
4:00 PM
8 hours
10:00 PM
6:00 AM (+1 day)
8 hours
9:00 AM
1:00 PM
4 hours
9:00 AM
12:00 PM
3 hours
8:30 AM
5:30 PM
9 hours
12:00 PM
5:00 PM
5 hours
How to calculate time duration
Calculating the hours and minutes between two times is straightforward once you know the steps. Here's the method used by this calculator:
Step 1 — Convert to 24-hour format
AM hours are the same in both 12-hour and 24-hour format. For PM hours, add 12. For example, 1:00 PM becomes 13:00, and 5:30 PM becomes 17:30. Midnight is 00:00 and noon is 12:00.
Step 2 — Subtract start from end
Subtract the start time from the end time. If both the hours and minutes are straightforward, the subtraction is simple:
Example: 17:30 − 09:00 = 8 hours 30 minutes
Step 3 — Handle the minutes carefully
If the end minutes are smaller than the start minutes, borrow 1 hour (60 minutes) from the hours column:
If the end time is earlier than the start time and the shift crosses midnight, add 24 hours to the end time before subtracting:
Example: Night shift 22:00 to 06:00 → 06:00 + 24:00 = 30:00 → 30:00 − 22:00 = 8 hours
Converting to decimal hours
For payroll and billing, you may need hours in decimal format. Divide the minutes by 60 and add to the hours. For example, 7 hours 45 minutes = 7 + (45 ÷ 60) = 7.75 hours.
Frequently asked questions
There are exactly 8 hours between 9:00 AM and 5:00 PM. If the end time is 5:30 PM, the duration is 8 hours 30 minutes. Use the calculator above to get the exact result for any pair of times.
For night shifts that cross midnight — such as 10:00 PM to 6:00 AM — select the "Yes — crosses midnight" option in the calculator above. It automatically adds 24 hours to handle the day change. A 10 PM to 6 AM shift is exactly 8 hours.
Divide the minutes by 60 and add to the hours. Examples: • 7 hours 30 minutes = 7.5 hours • 8 hours 45 minutes = 8.75 hours • 6 hours 20 minutes = 6.33 hours The calculator above shows the decimal hours automatically in the result.
There are 150 minutes in 2.5 hours. Multiply hours by 60 to convert to minutes. So 2.5 × 60 = 150 minutes. Similarly, 1.5 hours = 90 minutes, 3.5 hours = 210 minutes.
There are 3,600 seconds in one hour. This is because 1 hour = 60 minutes, and each minute = 60 seconds. So 60 × 60 = 3,600 seconds per hour.
Time duration and time difference mean the same thing — the total amount of time elapsed between a start time and an end time. Both are calculated by subtracting the start from the end time.
To find the time between two specific dates and times, use our Date Difference Calculator. It calculates the exact number of days, hours, and minutes between any two date-and-time combinations.