Article — Count Hours Calculator
To count hours worked, subtract the start time from the end time and then subtract unpaid breaks. A 09:00 to 17:30 shift with a 60-minute lunch comes to 7 hours and 30 minutes, or 7.5 hours on a payroll spreadsheet. The math is one subtraction. The complications — overnight shifts that cross midnight, paid versus unpaid breaks, rounding rules used by payroll software, and overtime that kicks in past 40 hours per week under U.S. federal law — are where the cleanly stated formula gets messy.
This article walks through how the calculation actually works, what the U.S. Department of Labor and equivalent regulators in Europe count as "hours worked," and the rounding habits that decide whether your timesheet matches your paycheck.
What it means to count hours
"Hours worked" is a legal term, not just an arithmetic one. The U.S. Fair Labor Standards Act (FLSA) defines it as time an employee is "suffered or permitted" to work — any time during which the employer benefits from the employee's presence, including waiting time when the worker is on call at the workplace. Time spent commuting from home is usually excluded; time spent travelling between job sites during the day usually is not.
The base calculation is simple: end time minus start time, less unpaid breaks. A standard 9-to-5 desk job with a 60-minute lunch comes to 7 hours of paid time, not 8. A 12-hour hospital shift with a 30-minute meal break is 11 hours and 30 minutes — 11.5 decimal hours on the payroll system.
The 8-hour day was not federal law in the U.S. until 1938. The Fair Labor Standards Act set 40 hours per week as the threshold above which overtime must be paid at 1.5 times the regular rate — not a cap, just a price signal. Many workers still routinely exceed it; the average U.S. full-time worker logged 41.8 hours per week in 2023 according to the Bureau of Labor Statistics.
Counting hours across midnight
An overnight shift — security guard 22:00 to 06:00, nurse 19:00 to 07:00 — breaks the basic subtraction. If you compute 06:00 minus 22:00, the answer is negative 16 hours. To get the right result, add 24 hours (1,440 minutes) to the end time before subtracting. So 06:00 becomes 30:00 in arithmetic terms, and 30:00 minus 22:00 returns the correct 8 hours.
The calculator above handles this with the "Shift crosses midnight" toggle. Modern timesheet software does it automatically by storing each punch with its date stamp rather than just the time of day — the system sees a punch out at 06:00 the next morning and knows it belongs to the previous evening's shift.
- 22:00 to 06:00 — 8 hours gross, the most common overnight shift
- 19:00 to 07:00 — 12 hours, typical for hospital nursing
- 23:00 to 07:00 — 8 hours, common warehouse third shift
- 20:00 to 04:00 — 8 hours, retail closing-plus-restock pattern
- Night-shift differential — typically +10 to +25% on the base rate
Which breaks count and which do not
U.S. federal law (29 CFR 785.18) requires short rest breaks — usually 5 to 20 minutes — to be counted as paid working time. Meal breaks of 30 minutes or more can be unpaid, provided the employee is "completely relieved from duty" during the break. A worker who eats lunch at their desk while still answering phones is technically on the clock; the IRS and DOL have both ruled on this.
The European Union Working Time Directive (2003/88/EC) requires a rest break for any shift longer than 6 hours, with the length and pay status determined by national law. In the UK, the 20-minute minimum break for a 6-hour shift is typically unpaid. In Germany, the Arbeitszeitgesetz mandates a 30-minute break for shifts of 6 to 9 hours, and 45 minutes for longer shifts.
If your employer expects you to keep answering calls, emails, or customer requests during your lunch break, that break legally counts as paid working time under FLSA. Document it on your timesheet. Wage-and-hour disputes over unpaid working lunches accounted for a significant share of the $274 million in back wages the U.S. Department of Labor recovered in FY2023.
Converting hours to decimal for payroll
Most payroll software stores time as decimal hours, not hours and minutes. The conversion is straightforward: divide the minute portion by 60. So 7 hours 30 minutes becomes 7.5; 7 hours 15 minutes becomes 7.25; 7 hours 45 minutes becomes 7.75. Awkward minute counts — 7 hours 20 minutes — convert to repeating decimals (7.333...). Payroll systems typically round to two decimal places.
The standard rounding rule under FLSA is the "7-minute rule": punches within 7 minutes of a quarter hour can be rounded to the nearest quarter, provided the rounding averages out over time and does not systematically favour the employer. Punch in at 8:53, get rounded to 8:45 in the worker's favour; punch in at 9:08, get rounded to 9:15 against the worker. The rule is legal only if both directions are applied consistently.
The decimal-hours convention dates back to early 20th-century factory timekeeping. Time-and-motion engineers like Frederick Taylor pushed for it because hours-and-minutes arithmetic produced too many errors when adding up weekly totals across hundreds of workers. Decimal hours add and multiply like ordinary numbers; hours-and-minutes need carry-the-60 logic that punch-card readers and early computers struggled with.
Counting hours for overtime pay
Under the FLSA, U.S. non-exempt employees earn 1.5 times their regular rate for every hour above 40 in a workweek. The workweek is a fixed 168-hour period that does not have to align with the calendar week — employers can define it Monday to Sunday, Sunday to Saturday, or any other consistent 7-day window. Daily overtime (over 8 hours in one day) is not required by federal law, but several states, including California, Alaska, Nevada, and Puerto Rico, mandate it.
Counting overtime correctly means tracking hours by day, summing them by workweek, and applying the multiplier only to the hours above 40. If you work 9 hours Monday through Thursday (36 hours) and 10 hours Friday (46 total), the first 40 are paid at the regular rate and the last 6 at time-and-a-half — not all 10 Friday hours.
- 40-hour week — FLSA threshold for federal overtime
- 1.5x rate — standard U.S. overtime multiplier
- 2x rate — California double-time after 12 hours in a day
- Workweek — any fixed 168-hour period, employer-defined
- Salaried non-exempt — still earns overtime; salary just covers the first 40 hours
Common mistakes when counting hours
The single most common error in any hours calculator is entering 22:00 and 06:00 without flagging the shift as overnight. The calculator returns either a negative number or zero. Always check whether the end time is before the start time on the clock face — if so, the shift crosses midnight.
Writing "7.30" when you mean 7 hours 30 minutes is the second most common error. In decimal hours, 7.30 means 7 hours and 18 minutes (0.30 x 60). The correct decimal for 7 hours 30 minutes is 7.50. Pick one format and stick with it across the whole timesheet.
If your lunch break is unpaid, do not include those minutes in the hours-worked total. A shift of 09:00 to 17:30 with a 60-minute unpaid lunch is 7 hours 30 minutes worked, not 8 hours 30 minutes. Conversely, paid rest breaks under 20 minutes do count as worked time under FLSA.