Hours Between Calculator

Select a start date and time, select an end date and time, and get the exact elapsed duration in hours, minutes, and days. Choose 24-hour time or AM/PM input.

Time format
Examples

From 09:00 to 17:30 on the same date.

Duration
0d 8h 30m
Decimal hours
8.5 h
Total minutes
510 min
Total days
0.3542 days

Same-day interval.

Was this useful?

Examples

How It Works

Formula

startMinutes=dateIndexstart×1440+hourstart×60+minutestart\text{startMinutes} = \text{dateIndex}_{start} \times 1440 + \text{hour}_{start} \times 60 + \text{minute}_{start}

endMinutes=dateIndexend×1440+hourend×60+minuteend\text{endMinutes} = \text{dateIndex}_{end} \times 1440 + \text{hour}_{end} \times 60 + \text{minute}_{end}

durationHours=(endMinutesstartMinutes)/60\text{durationHours} = (\text{endMinutes} - \text{startMinutes}) / 60

Variables

dateIndex\text{dateIndex}

Whole calendar-day index for the selected date

startMinutes\text{startMinutes}

Start date-time converted to total minutes

endMinutes\text{endMinutes}

End date-time converted to total minutes

durationHours\text{durationHours}

Elapsed minutes divided by 60

14401440

Minutes in one day

Choose the start and end date-times. The calculator converts each local date-time into a minute index, subtracts the start from the end, and shows the difference as days-hours-minutes, decimal hours, total minutes, and total days.

Each selected date is converted to a whole-day index, then the selected hour and minute are added. Subtracting the start minute index from the end minute index gives the elapsed minutes. Negative intervals are rejected so the result is never ambiguous.

Frequently Asked Questions

01Does it handle intervals across midnight?
Yes. Because both inputs include a date, midnight crossings are handled by the selected dates instead of a separate overnight toggle.
02Can I use AM/PM instead of 24-hour time?
Yes. Change the Time format control to AM/PM and the hour dropdowns switch to 1-12 with an AM/PM selector. The stored value remains unambiguous.
03Does this include time zones or daylight saving changes?
No. The calculator treats the selected date and time as local civil values and measures the calendar-clock difference between them.
04Why was the break field removed?
This calculator now measures pure elapsed time between two date-times. Breaks, payroll rules, and shift policy belong in a separate work-hours calculator.

All calculators