Time Duration Calculator

Duration0y 11m 30d 8h 0m
Total Days365

The Time Duration Calculator measures how much elapsed time separates two points on the calendar, combining a calendar-date difference with a clock-time difference. It breaks the gap down into years, months, and days alongside the leftover hours and minutes, and also reports the total number of days. This makes it handy for project timelines, age-style spans, contract periods, or any "how long between these two moments" question.

How it works

  1. Enter a start date with its start time (HH:MM) and an end date with its end time. The calendar portion is compared with year/month/day arithmetic that accounts for differing month lengths.
  2. The clock portion subtracts the start minutes-of-day from the end minutes-of-day; if the end time is earlier in the day than the start time, one day is borrowed and 24 hours are added so the hours and minutes stay positive.
  3. Read the breakdown as years, months, days, hours, and minutes, plus a total-days figure for the whole span.

Worked examples

A task starts on January 1 at 09:00 and finishes on March 15 at 17:30 of the same year.

  1. Calendar difference from Jan 1 to Mar 15: 0 years, 2 months, 14 days.
  2. Clock difference: 17:30 minus 09:00 = 8 hours 30 minutes (no day borrow needed).
  3. Total elapsed days from start date to end date: 74 days.

2 months, 14 days, 8 hours, 30 minutes (74 total days).

An overnight shift runs from Jan 1 at 22:00 to Jan 2 at 06:00.

  1. Calendar difference Jan 1 to Jan 2 is 1 day, but the end clock time (06:00) is earlier than the start (22:00).
  2. Borrow one day: subtract 1 from days and add 24 hours, giving 06:00 + 24:00 − 22:00 = 8 hours.

0 days, 8 hours, 0 minutes (1 total day between the calendar dates).

Frequently asked questions

Does this calculator count seconds?
No. The time inputs use hours and minutes (HH:MM), so the smallest unit reported is minutes. If you need second-level precision you would need a stopwatch-style timer instead.
What happens if the end time is earlier in the day than the start time?
The calculator borrows one day from the day count and adds 24 hours to the clock difference. This keeps the hours and minutes positive while correctly reducing the day total by one.
How is the total-days figure different from the years/months/days breakdown?
The breakdown describes the gap in mixed calendar units, while total days is the single flat count of days between the two dates. For example, two months and fourteen days can equal seventy-four total days.
How does it handle different month lengths?
The date math compares the actual calendar months, borrowing days from the previous month when the end day is smaller than the start day, so a span ending mid-month is counted correctly across 28-, 30-, and 31-day months.