How to Calculate Employee Timesheet Hours
If you've ever squinted at a stack of clock-in and clock-out times trying to figure out who worked how long, you know timesheet math looks simple until it isn't. A few extra minutes here, a lunch break there, and a shift that crosses midnight, and suddenly a simple subtraction problem turns into something you have to double-check twice before running payroll.
Here's exactly how the calculation works, step by step, plus the three things that trip people up most often: lunch deductions, rounding rules, and overnight shifts.
Quick summary: To calculate timesheet hours, subtract clock-in time from clock-out time, subtract any unpaid break time, then apply your rounding rule. For overnight shifts, add 24 hours when the clock-out time is earlier than the clock-in time. A timesheet calculator handles these steps automatically.
The basic formula
At its core, calculating hours worked comes down to one subtraction:
Hours worked = Time Out − Time In
If someone clocks in at 8:00 AM and clocks out at 4:30 PM, that's 8.5 hours. Multiply that across a pay period and you technically have your total. In practice, though, three complications show up in almost every real timesheet: unpaid breaks, rounding, and shifts that cross midnight.
Subtracting lunch and unpaid breaks
Many employers treat meal breaks as unpaid, provided the employee is fully relieved of duties, so the real formula usually looks like this:
Hours worked = (Time Out − Time In) − unpaid break time
A flat 30-minute deduction per shift is a common default, but it varies by company policy and local labor law, and it can vary day to day within the same employee's week. Someone might take a full 30-minute lunch on Monday, a rushed 15-minute break on Tuesday, and skip lunch entirely on a short Friday shift. If a timesheet only supports one lunch setting for the whole week, days like that get calculated incorrectly, and the errors add up fast across a full team.
A worked example
Here's how it looks in practice for one employee across a few different days, using a 15-minute nearest-rounding rule:
- Monday — 8:00 AM to 4:30 PM, 30-minute lunch → 8.50 raw hours → 8.00 paid hours
- Tuesday — 8:07 AM to 4:32 PM, 30-minute lunch → 8.42 raw hours → 8.00 paid hours
- Wednesday — 10:00 PM to 6:00 AM, 30-minute lunch → 8.00 raw hours → 7.50 paid hours
(overnight shift)
Tuesday shows why rounding matters: 8 hours 25 minutes worked, minus a 30-minute lunch, leaves 7 hours 55 minutes, which rounds up to 8.00 under a "nearest" rule. Wednesday shows the overnight-shift adjustment: 8 hours raw, minus lunch, comes out to 7.50. This is why a timesheet calculator needs to handle each day separately instead of applying one flat rule to the whole week.
Rounding rules
Some companies pay employees to the exact minute, while others round each day's total to the nearest 5, 10, or 15 minutes, with 15-minute rounding being the most common convention. But "rounding" isn't a single rule; there are three approaches, and they can produce meaningfully different totals:
- Round to nearest: 8 hours 7 minutes rounds down to 8:00, while 8 hours 8 minutes rounds up to 8:15
- Always round up: any time worked past an interval rounds up to the next one, favoring the employee
- Always round down: reduces paid time and can create compliance issues in some jurisdictions if it systematically underpays employees over time
Which one applies depends entirely on company policy. It's worth confirming which rule your business actually uses, since the difference between "nearest" and "always up" can add up to real money over a year of pay periods.
Handling overnight shifts
Overnight shifts break the simple subtraction formula. If someone clocks in at 10:00 PM and clocks out at 6:00 AM, a naive Time Out − Time In calculation produces a negative number, since 6:00 AM comes "before" 10:00 PM on the clock. The fix is to detect when Time Out is earlier than Time In and add 24 hours before subtracting, which turns that shift into a correct 8 hours (or 7.5, once a lunch deduction is applied).
Doing it by hand vs. using a calculator
For a single employee on a single day, this math is easy to do in your head. For a full week, multiple employees, mixed lunch breaks, and a specific rounding policy, it gets tedious and error-prone fast, and payroll is exactly the kind of place where small errors compound.
Our Timesheet Calculator handles all of this automatically. Enter each employee's clock-in and clock-out times for the week, set your rounding interval and direction, and it takes care of lunch deductions and overnight shifts for you. It also totals each employee's week and rolls everything into a summary across your whole team, so nobody has to add it up by hand.
If you also need to figure out how many working days fall in a longer pay period, the Work Days Calculator handles that separately, with support for weekends and holidays.
FAQ
What's the most common rounding rule for timesheets? Rounding to the nearest 15 minutes is the most widely used convention, though some companies round up or down instead, depending on their policy.
Do I have to deduct lunch every single day? Not necessarily. Some shifts don't include a lunch break at all, especially short ones. A good timesheet calculation should let you adjust or skip the deduction on a day-by-day basis rather than applying one flat rule across the whole week.
How do you calculate hours for an overnight shift? Add 24 hours to the Time Out value before subtracting Time In, since the shift crosses midnight. This turns what would otherwise be a negative number into the correct total.
Is rounding employee time legal? In some jurisdictions, including under U.S. federal guidance, rounding is generally allowed if it's applied neutrally and doesn't systematically underpay employees over time. Rules vary by country, state or province, and industry, so if you're unsure how rounding applies to your business, it's worth checking local labor standards or consulting a payroll or HR professional.
Can I calculate hours for multiple employees at once? Yes. Tools like our Timesheet Calculator let you add a card per employee and see a combined summary, which is much faster than calculating each person's hours separately.