How to Calculate Hours Worked (With a Lunch Break and Overnight Shifts)
A step-by-step way to total a shift: subtract an unpaid lunch, handle shifts that cross midnight, and convert minutes to decimal hours for a timesheet.

Most timesheet errors come from one of three places: a lunch break that was never subtracted, a shift that crosses midnight, and minutes converted to decimal in a hurry. All three are easy to get right once you work in minutes instead of hours.
The method
- Write the start and end time in 24-hour format. 5:30 PM becomes 17:30.
- Convert both to minutes since midnight. 9:00 is 540, 17:30 is 1050.
- Subtract. If the end time is smaller than the start time, the shift crosses midnight, so add 1440 minutes to the end time first.
- Subtract the unpaid break. A 30-minute lunch comes out of the total.
- Divide the minutes by 60 to get decimal hours. 480 minutes becomes 8.00.
Stay in minutes the whole way. Rounding the hours at the start is where mistakes get baked in.
The 1440 in step 3 is the number of minutes in a day. Once a shift passes midnight, the end time is a smaller number than the start time, so a day has to be added back before the subtraction makes sense.
Example 1: 9:00 to 17:30 with a 30-minute lunch
start 9:00 = 540 minutes
end 17:30 = 1050 minutes
span = 1050 - 540 = 510 minutes
lunch = -30 minutes
total = 480 minutes
decimal = 480 / 60 = 8.00 hoursThe shift covers eight and a half hours of clock time. Take out the 30-minute unpaid lunch and the answer is 8.00 hours.
Example 2: 8:45 to 17:15 with a 45-minute lunch
start 8:45 = 525 minutes
end 17:15 = 1035 minutes
span = 1035 - 525 = 510 minutes
lunch = -45 minutes
total = 465 minutes
decimal = 465 / 60 = 7.75 hours465 divided by 60 is exactly 7.75, so nothing needs rounding. This is the same span of clock time as example 1 with a different lunch, and that is where the half hour difference comes from.
Example 3: 22:00 to 06:30 with a 30-minute break
start 22:00 = 1320 minutes
end 06:30 = 390 minutes
end crosses midnight, so 390 + 1440 = 1830
span = 1830 - 1320 = 510 minutes
break = -30 minutes
total = 480 minutes
decimal = 480 / 60 = 8.00 hoursThe rule to remember: when the end time is earlier than the start time, add a full day, 1440 minutes, to the end time before subtracting. A shift like this also spans two calendar dates, so a timesheet that records the date as well as the time will show the shift on both days.
Minutes to decimal hours
Divide by 60. These are the values that come up most often.
- 5 minutes = 0.08 hours
- 10 minutes = 0.17 hours
- 15 minutes = 0.25 hours
- 20 minutes = 0.33 hours
- 30 minutes = 0.50 hours
- 45 minutes = 0.75 hours
- 60 minutes = 1.00 hour
- 90 minutes = 1.50 hours
- 120 minutes = 2.00 hours
The two values that look awkward, 0.08 and 0.17, are rounded. 5 divided by 60 is 0.0833 and 10 divided by 60 is 0.1667. If the payroll system wants exact minutes, submit the minutes and let the system do the division.
Why timesheets use decimal hours
Decimal hours make a pay period easy to total and easy to pay. 7.75 hours at 22.00 an hour is 170.50, which is a much easier sheet to check than 7 hours and 45 minutes multiplied by a rate. Keep the minutes as your working number, then convert to decimal when you write the total.
Five totals worth memorising
- 8:30 to 17:00 with a 30-minute lunch: 510 minutes of clock time, 480 after the break, 8.00 hours.
- 7:00 to 17:00 with a 30-minute lunch: 600 minutes, 570 after the break, 9.50 hours.
- 12:00 to 20:30 with a 30-minute lunch: 510 minutes, 480 after the break, 8.00 hours.
- 22:00 to 06:00 with a 30-minute break: 480 minutes across midnight, 450 after the break, 7.50 hours.
- 9:00 to 13:00 and 14:00 to 18:00: 240 minutes plus 240 minutes, 8.00 hours, with the unpaid hour in the middle already excluded.
Weekly totals
Add the minutes for the week first, then convert once. Converting each day separately and adding the decimals gives the same answer, but only when nothing was rounded on the way.
Monday 480 minutes
Tuesday 465 minutes
Wednesday 480 minutes
Thursday 510 minutes
Friday 360 minutes
week total = 2295 minutes
decimal = 2295 / 60 = 38.25 hoursThirty-eight hours and fifteen minutes. If that week had one fewer 15-minute break, the total would be 2280 minutes, which is exactly 38.00 hours.
Which breaks come out of the total
Whether a break is deducted is a policy question, not an arithmetic one. A meal break is often unpaid because you are free to leave the workplace, while a short rest break is often treated as worked time. Wikipedia's overview of working time notes that the hours people actually work vary in practice precisely because some employers count breaks as part of the working week and others do not.
The same shift can therefore be 8.00 or 8.50 hours depending on the rule. Settle that first, then do the math.
Rounding: check the rule before you round
Rounding up looks generous and increases the payroll total. Rounding down does the opposite. Some employers round to the nearest quarter hour, some to the nearest 15 minutes, and some do not round at all.
Watch for rounding that works against the worker. Wikipedia's write-up of California overtime law gives a specific example: rounding a six-hour day and a ten-hour day into two eight-hour days would take two hours of overtime pay away from the worker. When your employer rounds, the direction matters.
A habit that holds up well is to keep the raw minutes in the sheet and round once, at the end of the week or the pay period, following the employer's stated rule.
Edge cases worth writing down
- A shift that crosses midnight: add 1440 minutes to the end time, as in example 3.
- A break that crosses midnight, for example 23:45 to 00:15. Convert both ends the same way and the break is 30 minutes.
- Two shifts in one day, for example a split shift. Calculate each one separately and add the two totals.
- A 24-hour shift: 1440 minutes, which is 24.00 hours. Check how your employer records a full day before you submit it.
- Times written in 12-hour format: convert them first, so 5:30 PM does not quietly become 5:30 AM.
Let the calculator do the subtraction
The hours between times calculator takes two clock times and gives you the span between them, so you can subtract the break and read the decimal straight away. It is a useful second check when you are filling in a timesheet by hand.
One last check on the rules
This is arithmetic, not legal advice. Whether a break is unpaid, how rounding works and when overtime starts come from your employment contract, your employer's policy and the labour law where you work. Wikipedia's summary of overtime rules shows how much these differ between places: the European Union working time directive caps the average working week, including overtime, at 48 hours over a 17-week reference period, asks for a break when the working day runs past six hours, and requires at least 11 consecutive hours of daily rest in every 24. United States federal law sets a 40-hour work week with overtime paid at one and a half times the normal rate for many workers. Check your own rules before you file the numbers.
Sources
- Working time, Wikipedia: why the hours people actually work vary between employers, and how standard working weeks differ by country. en.wikipedia.org
- Overtime, Wikipedia: the European Union working time limits, United States federal overtime rules, and the California example about rounding workdays. en.wikipedia.org