A start time and end time with a break, illustrating how to calculate hours worked for a timesheet
Everyday · 6 min read

How to calculate hours worked

Hours worked is the time between clocking in and out, minus any unpaid break. Here is the method, how to convert to decimal hours for pay, how to handle shifts that cross midnight, and how overtime fits in.

Do the mathsHours Calculator

Work out the hours between a start and end time, minus any break.

Working out hours worked sounds trivial until the times cross midnight, a break needs taking off, or payroll wants the answer in decimal hours rather than hours and minutes. The method itself is simple: it is the time from clocking in to clocking out, minus any unpaid break. This guide shows that method, how to turn the result into decimal hours for pay, how to handle overnight shifts, and how overtime works. A free hours calculator does it instantly, including shifts that pass midnight, but the steps below are quick to learn.

How to calculate hours worked: the basic method

To find hours worked, take the end time, subtract the start time, then subtract any unpaid break:

Hours worked = end time − start time − unpaid break

Worked example: a shift from 09:00 to 17:30. From 09:00 to 17:30 is 8 hours and 30 minutes of clock time. Take off a 30-minute unpaid lunch break and you have 8 hours of paid time. If the times are in 12-hour form, convert to 24-hour first (5:30 pm is 17:30) so the subtraction is straightforward.

Converting to decimal hours for pay

Payroll almost always wants decimal hours, because you multiply decimal hours by an hourly rate to get pay. To convert minutes to a decimal, divide the minutes by 60:

So 8 hours and 30 minutes is 8.5 hours. At a rate of, say, 15 an hour, that shift is worth 8.5 × 15 = 127.50 (or 8 × 15 = 120 if the half hour was the unpaid break). The common mistake is writing 8 hours 30 minutes as "8.30" and multiplying that; 8.30 is not 8 and a half hours, it is 8.3, which underpays you.

Shifts that cross midnight

When a shift starts one day and ends the next, subtracting the start from the end gives a negative number, which is the usual trip-up. The fix is to add 24 hours to the end time before subtracting. A shift from 22:00 to 06:00 is (06:00 + 24:00) − 22:00 = 30:00 − 22:00 = 8 hours. Add the 24 hours only when the end time is earlier than the start. A good calculator does this automatically, and in a spreadsheet the formula =MOD(end − start, 1) × 24 handles the wrap for you. One edge case to watch: on the nights the clocks change for daylight saving, a 22:00 to 06:00 shift can actually run 7 or 9 hours, not 8.

Breaks, paid and unpaid

Only subtract unpaid breaks. If your lunch is paid, it stays in the total; if it is unpaid, take it off. Where there are several breaks, add up all the unpaid minutes and subtract the total once. The length and payment of breaks are set by your contract or local law, so check what applies to you rather than assuming.

How overtime works

Overtime is hours beyond a set threshold, usually paid at a higher rate. The threshold might be a daily one (anything over 8 hours in a day) or a weekly one (anything over 40 hours in a week), depending on your rules. Split the hours into standard and overtime, then pay each at its rate. A worked example: you work 45 hours in a week with a 40-hour standard week, so 40 hours are standard and 5 are overtime at time and a half. At a 20 base rate, that is (40 × 20) + (5 × 30) = 800 + 150 = 950 for the week. Always check your actual overtime rule, because thresholds and multipliers vary by country and contract: time and a half after 40 hours is a US-style example, while some places use daily thresholds, some have no statutory overtime, and rates may be 1.25, 1.5 or 2 times.

A quick weekly timesheet method

For a timesheet, calculate each day's hours the same way (end minus start minus break), convert each to decimal, then add the days together for the week. For example, five days of 8 paid hours is 40.0 hours; add a day with 8 hours 45 minutes (8.75) and the week is 48.75 hours. Keeping every day in decimal from the start makes the weekly total a simple sum, and makes pay a single multiplication.

Common mistakes

Subtract start from end, take off the unpaid break, and convert minutes to a decimal by dividing by 60, and hours worked is quick to get right. When you want it done at once, including overnight shifts, the free hours calculator turns a start time, end time and break into paid hours ready to multiply by your rate, and the date difference calculator handles whole days between two dates.

Frequently asked questions

How do you calculate hours worked?

Subtract the start time from the end time, then subtract any unpaid break. A shift from 09:00 to 17:30 is 8 hours 30 minutes of clock time, and taking off a 30-minute unpaid break leaves 8 paid hours. Convert both times to 24-hour form first so the subtraction is straightforward.

How do I convert hours and minutes to decimal for pay?

Divide the minutes by 60 and add to the hours. So 30 minutes is 0.5 and 45 minutes is 0.75, which makes 8 hours 30 minutes equal to 8.5 hours. Multiply decimal hours by your hourly rate to get pay. Do not write 8 hours 30 minutes as 8.30, which means 8.3 hours and underpays.

How do I calculate hours for a shift that crosses midnight?

Add 24 hours to the end time before subtracting the start, or the plain subtraction gives a negative number. A shift from 22:00 to 06:00 is (06:00 plus 24 hours) minus 22:00, which is 8 hours. Most hours calculators handle this automatically.

How is overtime calculated?

Overtime is hours above a threshold, often over 8 in a day or 40 in a week, paid at a higher rate. Split the hours into standard and overtime and pay each at its rate. For 45 hours on a 40-hour week at a 20 base rate with time and a half, that is 40 x 20 plus 5 x 30, which is 950. Check your own overtime rule, as it varies.

Calculators in this article

Hours Calculator

Work out the hours between a start and end time, minus any break.

Open

Date Difference Calculator

Pick two dates to count the days and weeks between them.

Open

Percentage Calculator

Three common percentage questions in one place, pick a mode and type your numbers.

Open