Inputs

Results update as you type. The link in the address bar keeps the inputs so you can share it.

24-hour clock, 0 to 23.

24-hour clock, 0 to 23.

What this means

  • The time worked is 8 hours, or 8.00 hours in decimal form.
  • Timesheets and payroll often use decimal hours: 30 minutes is 0.5 and 15 minutes is 0.25.

What if

No break Count the whole span. Duration: 8 hours 30 minutes.

About this calculator

What this calculator does

It converts both times to minutes after midnight, subtracts, adds a day if the end is earlier than the start, then removes the break.

How it is calculated

minutes = (end hour * 60 + end minute) - (start hour * 60 + start minute)

if end is not after start, add 1,440 minutes (one day)

decimal hours = minutes / 60

How to read the result

Duration is in hours and minutes. Decimal hours is the same time as a single number, which is what most pay calculations use.

Sources and method

Standard arithmetic with no outside data. The formula is shown under How it is calculated, and unit tests check worked examples, including edge cases. Equal start and end times count as 24 hours.

This page uses arithmetic only, with no outside data.

Questions

How do I enter 5:30 PM?

Hour 17, minute 30. Add 12 to afternoon hours, except 12 PM stays 12.

What about overnight shifts?

If the end time is earlier than the start time, the page assumes the shift ends the next day.

What is 7 hours 45 minutes in decimal?

7.75 hours, because 45 minutes is 0.75 of an hour.

Does it handle daylight saving changes?

No. On the night clocks change, adjust by one hour yourself.