Hours Calculator
Calculate hours between two times with breaks and overnight shifts, or total a weekly timesheet with pay and overtime.
- Free
- No sign-up
- Runs in your browser
Hours Calculator
Runs in your browser. Your inputs never leave your device.
In short
Quick Answer
To calculate hours worked, subtract the start time from the end time, then subtract any unpaid break. 9:00 AM to 5:30 PM with a 30-minute break is 8 hours 30 minutes minus 30 minutes = 8:00, or 8.00 decimal hours. If the end time is earlier than the start time, the shift crossed midnight, so add 24 hours to the end time first.
Step by step
How to Use
- Choose a mode. Use Time duration for a single shift, or Weekly timesheet to add up Monday to Sunday.
- Enter start and end times. Type or pick the start and end time. If the end is earlier than the start, the shift is treated as running past midnight.
- Enter the unpaid break. Add the unpaid break in minutes. Leave it at 0 if breaks are paid.
- Add pay details (optional). In the timesheet, enter an hourly rate and the overtime threshold and multiplier to see regular, overtime and total pay.
Hours and Minutes vs Decimal Hours
Clocks count in base 60 but payroll counts in base 10, which is where most timesheet errors come from. A shift of 7 hours 30 minutes is written 7:30 on a clock and 7.5 in decimal hours. To convert, divide the minutes by 60:
| Minutes | Decimal | Minutes | Decimal |
|---|---|---|---|
| 5 | 0.08 | 35 | 0.58 |
| 10 | 0.17 | 40 | 0.67 |
| 15 | 0.25 | 45 | 0.75 |
| 20 | 0.33 | 50 | 0.83 |
| 25 | 0.42 | 55 | 0.92 |
| 30 | 0.50 | 60 | 1.00 |
The calculator shows both forms side by side, so you can copy the clock format into a timesheet and the decimal format into a payroll or invoicing system.
When to Use the Weekly Timesheet
- Hourly employees: check that your payslip matches the hours you worked, including overtime above 40 hours.
- Freelancers and contractors: total billable hours for the week and multiply by your rate for an invoice.
- Shift workers: night shifts that end the next morning are handled per row, so a Friday 22:00 to Saturday 06:00 shift counts as 8 hours on Friday.
- Managers and small businesses: sanity-check rota hours before running payroll.
Overtime rules differ by country. In the US, the Fair Labor Standards Act requires 1.5 times the regular rate for hours over 40 in a workweek for non-exempt employees. In the UK there is no legal overtime premium, but the Working Time Regulations cap average working time at 48 hours a week unless you opt out. Set the threshold and multiplier to match your contract, or untick overtime to pay every hour at the same rate.
The math
Hours Worked Formula
Hours worked = (End time − Start time [+ 24 h if the end is earlier]) − Unpaid break
Both times are converted to minutes after midnight. If the end is earlier than the start, the shift ran past midnight and 1,440 minutes (24 hours) are added to the end. The unpaid break is subtracted, and the result is shown as hours and minutes (h:mm) and as decimal hours (minutes ÷ 60). For pay, hours up to the weekly overtime threshold are paid at the hourly rate, and hours above it at the rate times the overtime multiplier.
- Decimal hours: Minutes ÷ 60. 45 minutes is 0.75 hours, so 8 hours 45 minutes is 8.75 hours.
- Regular pay: min(total hours, overtime threshold) × hourly rate.
- Overtime pay: max(0, total hours − overtime threshold) × hourly rate × overtime multiplier.
Examples
Worked Examples
Day shift with a 30-minute lunch
Start: 09:00 · End: 17:30 · Unpaid break: 30 minutes
- 17:30 − 09:00 = 8 hours 30 minutes (510 minutes)
- 510 − 30 minute break = 480 minutes
- 480 ÷ 60 = 8.00 decimal hours
Result: 8:00 (8.00 hours)
Night shift that crosses midnight
Start: 22:00 · End: 06:00 (next morning) · Unpaid break: none
- The end time is earlier than the start, so add 24 hours: 06:00 becomes 30:00
- 30:00 − 22:00 = 8 hours
Result: 8:00 (8.00 hours)
Converting 8 hours 45 minutes to decimal
Start: 08:15 · End: 17:30 · Unpaid break: 30 minutes
- 17:30 − 08:15 = 9 hours 15 minutes (555 minutes)
- 555 − 30 = 525 minutes = 8 hours 45 minutes
- 45 ÷ 60 = 0.75, so 8:45 = 8.75 decimal hours
Result: 8:45 (8.75 hours)
45-hour week at 20 per hour with overtime
Monday to Friday: 08:00 to 17:00, no break (9 hours a day) · Hourly rate: 20 · Overtime after 40 hours at 1.5×
- Total: 5 × 9 = 45 hours
- Regular: 40 × 20 = 800
- Overtime: 5 × 20 × 1.5 = 150
Result: Total pay 950 (800 regular + 150 overtime)
Watch out
Common Mistakes to Avoid
- Writing 8:45 as 8.45 on a timesheet: 8 hours 45 minutes is 8.75 decimal hours, not 8.45. Payroll systems multiply decimal hours by the rate, so 8.45 underpays 18 minutes of work. Divide the minutes by 60: 15 min = 0.25, 30 min = 0.5, 45 min = 0.75.
- Getting a negative result for night shifts: A shift from 22:00 to 06:00 looks like −16 hours if you subtract directly. When the end time is earlier than the start, the shift ran into the next day: add 24 hours to the end time. This calculator does that automatically.
- Subtracting paid breaks: Only unpaid breaks should be deducted. Under US federal rules, short rest breaks of about 5 to 20 minutes are generally counted as paid working time, while bona fide meal periods of 30 minutes or more usually are not. Check your contract or local law.
- Working out overtime per day when the rule is per week: The US Fair Labor Standards Act sets overtime at 1.5× the regular rate for hours over 40 in a workweek, not per day. Some states (such as California) and many contracts add daily overtime, so a weekly total alone may not match your payslip.
- Mixing 12-hour and 24-hour times: 5:30 written without AM or PM is ambiguous. Use 24-hour times (17:30) or make sure the AM/PM setting on the time field is right, otherwise a shift can come out 12 hours too short or too long.
FAQ
Frequently Asked Questions
How do I calculate hours worked between two times?
Subtract the start time from the end time, then subtract unpaid breaks. For 8:30 AM to 5:00 PM with a 30-minute lunch: 17:00 − 8:30 = 8 hours 30 minutes, minus 30 minutes = 8 hours.
How do I convert hours and minutes to decimal hours?
Divide the minutes by 60 and add them to the hours. 7 hours 20 minutes = 7 + 20/60 = 7.33 hours; 8 hours 45 minutes = 8.75 hours; 6 hours 15 minutes = 6.25 hours.
How many hours is 9 to 5?
9:00 AM to 5:00 PM is 8 hours. With an unpaid 30-minute lunch it is 7.5 hours (7:30); with an unpaid one-hour lunch it is 7 hours.
How do you calculate hours for a shift that goes past midnight?
Add 24 hours to the end time before subtracting. 10:00 PM to 6:00 AM becomes 22:00 to 30:00, which is 8 hours. The calculator detects this when the end time is earlier than the start time.
How is overtime pay calculated?
Hours above the threshold (40 per week under the US FLSA) are paid at the regular rate times the multiplier, usually 1.5. For 45 hours at 20 per hour: 40 × 20 = 800 plus 5 × 30 = 150, so 950 in total.
How many hours is a full-time work week?
It depends on the country and employer. 40 hours (five 8-hour days) is common in the US, 37.5 hours is common in the UK, and 35 hours is the legal reference week in France. Enter your own hours and threshold in the timesheet.
Should lunch breaks be deducted from hours worked?
Deduct only unpaid breaks. If your employer pays for the break, leave the break field at 0 so it counts as working time.
Does this hours calculator save my timesheet?
Your entries stay in this browser only. They are kept in the page address so you can bookmark or copy a link to the result, and nothing is sent to a server.
References