Clock Duration Calculator

This calculator works out the exact elapsed time between two clock times, useful for timesheets, payroll, shift planning, travel times and working out how long has passed between a start point and an end point in the day. Enter your start time and end time using either 12-hour format with AM/PM or 24-hour format, whichever matches how your times are recorded. You can also set whether the times fall on the same day or the end time is next day; left on auto-detect, it assumes an overnight span whenever the end time is earlier than the start time, so a shift from 10pm to 6am reads correctly as 8 hours rather than a negative number. The results show the duration in hours and minutes, the total elapsed minutes, and the equivalent decimal hours, the format most payroll systems use when multiplying hours worked by an hourly rate. A calculation breakdown converts both times to minutes since midnight and shows any overnight adjustment applied, while a further table expresses the duration in total seconds and as a fraction of a day and a week. Use the 24-hour option if AM/PM is confusing, and double-check the overnight setting whenever a shift crosses midnight. The calculator works with clock times only and does not adjust for daylight saving, so times either side of a clock change need adjusting manually by an hour.

Calculate.co.nz is proud to be partnered with Health Based Building, a leader in sustainable and health-conscious building innovation. With over a century of experience, they develop high-performance systems like Foreverbreathe Specification, Magnum Board, and Foreverbreathe Paints to support energy-efficient, non-toxic living environments. Their commitment to healthier homes aligns with our belief that informed choices lead to better outcomes for Kiwi households.
Calculate.co.nz partner: Health Based Building
Advertise on this page
Standard method  Duration = end time minus start time (in total minutes). Overnight spans handled by adding 24 hours if end is before start.

1. Start Time

2. End Time

Please enter valid times (hour 1-12 for AM/PM or 0-23 for 24-hour, minutes 0-59).

Elapsed Duration

Duration
8h 30m
Hours and minutes
Total Minutes
510
Elapsed minutes
Decimal Hours
8.50
For timesheets
Overnight?
No
Spans midnight

Calculation Breakdown

Start time09:00 AM
End time05:30 PM
Start (minutes since midnight)540 min
End (minutes since midnight)1,050 min
Overnight adjustmentNone
Elapsed minutes510 minutes

Duration in Different Units

Hours and minutes8 hr 30 min
Decimal hours8.50 hrs
Total minutes510 min
Total seconds30,600 sec
Fraction of a day0.3542 of a day
Fraction of a week0.0506 of a week
Result: Enter your start and end times above to calculate the duration.

How to Calculate Duration Between Two Times

The duration between two clock times is found by converting both times to the total number of minutes since midnight, then subtracting the start from the end. If the result is negative (meaning the end time is earlier in the day than the start time), add 1,440 minutes (the number of minutes in 24 hours) to get the correct overnight duration.

The Formula

Convert each time to minutes since midnight:

Then: Elapsed minutes = End minutes - Start minutes

If Elapsed minutes is negative or you have selected "next day": Elapsed minutes = Elapsed minutes + 1,440

To convert elapsed minutes to hours and minutes: Hours = floor(Elapsed / 60), Minutes = Elapsed mod 60

To convert to decimal hours: Decimal hours = Elapsed minutes / 60

AM/PM to 24-Hour Conversion

12-hour24-hourMinutes since midnight
12:00 AM (midnight)00:000
6:00 AM06:00360
9:00 AM09:00540
12:00 PM (noon)12:00720
5:30 PM17:301,050
11:59 PM23:591,439

Worked Example

Default inputs: start 9:00 AM, end 5:30 PM.

This matches the calculator output of 8h 30m (510 total minutes, 8.50 decimal hours).

Overnight Duration Example

Start 10:00 PM, end 6:30 AM (next morning):

Common Uses

Related Calculators

Method: Standard time arithmetic. Duration in minutes = (end hour x 60 + end minutes) - (start hour x 60 + start minutes). If the result is negative, 1,440 minutes (24 hours) is added to reflect a span across midnight. Decimal hours = total minutes / 60.

This calculator works with clock times only and does not account for daylight saving transitions. For scheduling purposes that cross a daylight saving boundary, adjust times manually by one hour as appropriate.