Home › Time & Date › Time Duration Calculator

Time Duration Calculator

Enter a start time and an end time to get the exact duration in H:MM:SS, decimal hours, minutes and seconds. Overnight spans and multi-day dates are handled for you.

Start time
: :
End time
: :

Hours 0–23 in 24-hour mode, 1–12 with AM/PM in 12-hour mode. Seconds are optional.

Duration (H:MM:SS)–
Total hours–
Total minutes–
Total seconds–
Advertisement

How to use the Time Duration Calculator

  1. Pick a clock format: 24-hour or 12-hour with AM/PM.
  2. Enter the start and end time in hours, minutes and seconds, or press Now.
  3. Tick Include dates if the span covers more than one day, and choose the dates.
  4. Press Calculate to see the duration as H:MM:SS, decimal hours, minutes and seconds.
  5. Use Multiple rows to list several time ranges and get their total.

How to calculate the time between two times

Convert both times to seconds after midnight (hours × 3600 + minutes × 60 + seconds), subtract the start from the end, and convert the difference back to hours, minutes and seconds. If the end time is smaller than the start time, the span crosses midnight, so add 24 hours (86,400 seconds) before converting.

Example: a night shift from 22:30 to 06:15. The start is 22 × 3600 + 30 × 60 = 81,000 s and the end is 6 × 3600 + 15 × 60 = 22,500 s. The difference is −58,500 s, so add 86,400 s to get 27,900 s. That is 27,900 ÷ 3600 = 7.75 hours, or 7:45:00 (7 hours 45 minutes), or 465 minutes.

Converting minutes to decimal hours

Timesheets and payroll systems often want hours as a decimal number. Divide the minutes by 60: 45 minutes is 45 ÷ 60 = 0.75 hours, so 7 h 45 min becomes 7.75 h. The table shows common values.

MinutesDecimal hoursMinutesDecimal hours
50.083350.583
100.167400.667
150.25450.75
200.333500.833
250.417550.917
300.5601.0

12-hour and 24-hour clock

In the 12-hour clock, 12:00 AM is midnight and 12:00 PM is noon. To convert to the 24-hour clock, add 12 to any PM hour except 12 PM, and change 12 AM to 00. So 9:15 PM is 21:15 and 12:40 AM is 00:40. The calculator does this for you when you switch the clock format, and the result is the same in both modes.

12-hour24-hour12-hour24-hour
12:00 AM00:0012:00 PM12:00
3:30 AM03:303:30 PM15:30
6:45 AM06:456:45 PM18:45
11:59 AM11:5911:59 PM23:59

Spans longer than a day

Without dates, any two clock times are at most 24 hours apart. For longer spans, such as a 36-hour shift or a multi-day trip, tick “Include dates” and pick the start and end dates. The duration then shows total hours beyond 24 (for example 31:15:00) together with a days-hours-minutes breakdown. Daylight saving changes are not applied, so a span across a clock change may be off by an hour.

Frequently asked questions

How do I calculate the time between two times?

Convert both times to minutes or seconds after midnight, subtract the start from the end and convert back to hours and minutes. If the result is negative, the span crosses midnight, so add 24 hours.

How many hours is 22:30 to 06:15?

It is 7 hours 45 minutes, or 7.75 hours. The end time is earlier than the start, so the calculator treats it as the next morning.

What happens if the end time is earlier than the start time?

Without dates, the calculator assumes the end is on the next day and shows a note saying so. With dates switched on, an end before the start is reported as an error so you can fix the dates.

How do I convert minutes to decimal hours?

Divide the minutes by 60. For example 45 minutes is 0.75 hours and 20 minutes is about 0.333 hours, so 7 hours 45 minutes is 7.75 hours.

Can it calculate durations longer than 24 hours?

Yes. Tick Include dates and set a start and end date. The H:MM:SS result then goes beyond 24 hours, for example 52:30:00, and the breakdown shows days, hours and minutes.

Can I add up several time ranges?

Yes. Switch to Multiple rows, enter a start and end time on each row and the tool sums all the durations into one total, counting overnight rows correctly.

Related tools