Time duration calculator

Enter a start time, an end time and any unpaid break to get the time worked in hours and minutes and in decimal hours; an end time earlier than the start counts as the next day. Below it, enter durations one per line to add them up.

Time between two clock times
Duration—
Add up durations

Write hours:minutes (7:45), hours:minutes:seconds, or plain minutes (45). Start a line with a minus sign to subtract it.

Total—

Calculated in your browser. Nothing you enter is sent or stored.

How the length of a shift is worked out

The first calculator turns both clock times into minutes after midnight, subtracts the start from the end and then takes off the unpaid break. If the end time is earlier than the start, as in a shift from 22:00 to 06:30, the end is taken to be on the next day, so 24 hours are added before the break is removed.

The start and end fields are your browser’s time pickers, so they show the 12-hour or the 24-hour clock according to your device settings; 5:15 pm and 17:15 are the same entry. The result appears twice: as hours and minutes, which is how a clock reads, and as decimal hours, which is what most payroll and invoicing systems multiply by an hourly rate.

465 minPaid time, 09:00 to 17:15 less the breakUnpaid break
A 09:00 to 17:15 shift is 495 minutes; taking off a 30-minute break leaves 465 minutes, or 7.75 hours

The second calculator, Add up durations, totals a list. Put one duration on each line, either as hours and minutes (7:45) or as a plain number of minutes (90). The total can run past 24 hours, so a week of shifts adds up to a figure such as 38:15.

Formulas

duration = end − start (add 24 h if the end is earlier)paid time = duration − breakdecimal hours = hours + minutes ÷ 60minutes = decimal part × 60

Whole minutes convert to decimal hours exactly only when they are a multiple of 3 (6 minutes = 0.1 h). Others repeat forever, such as 10 minutes = 0.1666… h, so payroll systems round the decimal, usually to two places.

Minutes as decimal hours

Minutes Decimal hours
5 0.0833
6 0.1
10 0.1667
15 0.25
20 0.3333
30 0.5
40 0.6667
45 0.75
50 0.8333

Worked examples

Day shift from 09:00 to 17:15 with a 30-minute unpaid break
  1. 17:15 − 09:00 = 8 h 15 min.
  2. Take off the break: 8 h 15 min − 30 min = 7 h 45 min.
  3. In decimal hours: 45 ÷ 60 = 0.75, so 7.75 h.
7 h 45 min, or 7.75 decimal hours
Night shift from 22:00 to 06:30 with a 30-minute break
  1. The end time is earlier than the start, so it belongs to the next day.
  2. 22:00 to midnight is 2 h, and midnight to 06:30 is 6 h 30 min: 8 h 30 min in all.
  3. Take off the break: 8 h 0 min.
8 h 0 min, or 8 decimal hours
A week of shifts: 7:45, 8:30, 7:15, 8:00 and 6:45
  1. Add the hours: 7 + 8 + 7 + 8 + 6 = 36 h.
  2. Add the minutes: 45 + 30 + 15 + 0 + 45 = 135 min, which is 2 h 15 min.
  3. Total: 36 h + 2 h 15 min = 38 h 15 min, or 38.25 h.
38:15, or 38.25 decimal hours
Mixed entries: 1:15, 0:50, 45 and 2:05
  1. The line “45” has no colon, so it is read as 45 minutes.
  2. Minutes: 75 + 50 + 45 + 125 = 295 min.
  3. 295 ÷ 60 = 4 remainder 55, so 4 h 55 min, which is 4.9166… h.
4:55, or about 4.92 decimal hours

The 12-hour clock, noon and midnight

On the 12-hour clock, 12 am is usually taken to mean midnight and 12 pm noon, although the Royal Observatory Greenwich points out that, strictly, noon and midnight are neither am nor pm. In the time pickers, 12:00 am is midnight (00:00) and 12:00 pm is noon (12:00). The 24-hour clock avoids the question: 00:00 is the start of a day and 12:00 is noon. If a paper timesheet just says “12:00”, check whether it means noon or midnight before entering it.

Common timesheet errors

  • Reading 7:45 as 7.45 hours. 7 hours 45 minutes is 7.75 h. Billing 7.45 h at an hourly rate underpays by 0.3 h, which is 18 minutes.
  • Typing a decimal point in the add-up list. A line reading 7.45 is taken as 7.45 minutes (7 min 27 s). Write 7:45 for hours and minutes, or 465 for minutes.
  • Entering the same start and end time for a 24-hour shift. Equal times give a duration of zero. For shifts of a full day or more, add the parts as separate lines in the second calculator.
  • Forgetting the clock change. The calculator works with times on the clock face. On the night daylight saving time starts, a shift from 22:00 to 06:00 lasts 7 real hours, not 8, and on the night it ends it lasts 9.

Negative entries are allowed in the add-up list. A line such as -0:15 subtracts 15 minutes, which is handy for an unpaid break you forgot to take off a shift.

Sources

  1. Is noon 12 am or 12 pm?, Royal Museums Greenwich.
  2. RFC 3339: Date and Time on the Internet: Timestamps (section 5.6, 24-hour time of day), Internet Engineering Task Force.