Count Hours Calculator
Enter a start time and end time to count the exact number of hours and minutes between them. Optionally subtract a break, handle overnight shifts, and convert the result to decimal hours for payroll or timesheets. Results update as you type.
Formula
Worked example
Start 09:00, end 17:30, 30 min break: (17:30 - 09:00) = 510 min gross; 510 - 30 = 480 min net; 480 / 60 = 8.00 decimal hours.
How to count hours between two times
To count the hours between two times, convert both to minutes from midnight, subtract the start from the end, then divide by 60. For example, 09:00 is 540 minutes and 17:30 is 1050 minutes; the difference is 510 minutes, or 8.50 decimal hours. This calculator does all of that automatically and also subtracts any break time you enter, so the result is the net paid duration you can enter directly into a payroll system.
Decimal hours vs. hours and minutes
Payroll software almost always requires decimal hours rather than the hh:mm format you read on a clock. To convert minutes to a decimal fraction, divide by 60: 15 min = 0.25 h, 30 min = 0.50 h, 45 min = 0.75 h. This calculator shows both formats side by side so you never have to do that conversion by hand. If your rate is, for example, $18 per hour and you worked 7.75 decimal hours, your gross pay is $18 x 7.75 = $139.50.
Overnight and night-shift calculations
When the end time is earlier on the clock than the start time (e.g. you start at 22:00 and finish at 06:00), the calculator automatically adds 24 hours to the end time so the math stays correct. The default setting is "auto-detect," which triggers whenever end < start. If your work day runs from an unusual pattern and the auto-detect is wrong, you can override it with "same day" (end must be strictly after start) or "force next day" (always treat the end as the following calendar day).
Break deductions and labor law
Most employment laws require that unpaid breaks are not included in hours worked. A typical 8-hour shift includes a 30-minute unpaid lunch, leaving 7.5 paid hours. Enter your total unpaid break time in minutes and the calculator subtracts it before showing the net result. If you have multiple breaks, add them together first. Note that laws on mandatory break lengths vary by country, state, and industry - always check your jurisdiction.
Common shift lengths and decimal equivalents
| Shift duration | Decimal hours | Typical use |
|---|---|---|
| 2 h 00 min | 2.00 | Short call / on-call |
| 3 h 00 min | 3.00 | Half-day part-time |
| 4 h 00 min | 4.00 | Standard part-time |
| 6 h 00 min | 6.00 | Short full shift |
| 7 h 30 min | 7.50 | 9:00-17:00 with 30 min break |
| 8 h 00 min | 8.00 | Standard 8-hour shift |
| 8 h 30 min | 8.50 | 9:00-18:00 with 30 min break |
| 10 h 00 min | 10.00 | Extended/10-hour shift |
| 12 h 00 min | 12.00 | 12-hour shift (hospital, plant) |
| 12 h 30 min | 12.50 | 12-hour shift with 30 min break |
Quick reference for converting hours:minutes to decimal hours used in payroll.
Frequently asked questions
How do I count hours worked for payroll?
Enter your clock-in time as the start and your clock-out time as the end, then enter any unpaid break in minutes. The calculator shows both the hh:mm total and the decimal-hour equivalent. Use the decimal hours number in your payroll system and multiply it by your hourly wage for gross pay. For a full week, repeat for each day and sum the daily decimal totals.
What are decimal hours and why do they matter?
Decimal hours express a time duration as a single number with a decimal fraction instead of separate hours and minutes. For example, 7 hours and 30 minutes = 7.50 decimal hours. Payroll spreadsheets and most timekeeping software require this format because you can multiply it directly by an hourly rate. The conversion is simple: divide the minutes part by 60 and add it to the whole hours (30 min / 60 = 0.50, so 7 h 30 min = 7.50 h).
How does overnight shift calculation work?
When the end time is earlier than the start time (e.g. start at 22:00, end at 06:00), this calculator automatically adds 24 hours (1440 minutes) to the end time before subtracting. The result is 06:00 + 24h - 22:00 = 30:00 - 22:00 = 8 hours, which is correct for an overnight shift. You can also set the overnight toggle to "force next day" if you always want this behavior.
How do I convert 7 hours 45 minutes to decimal?
Divide the minutes by 60: 45 / 60 = 0.75. Add that to the hours: 7 + 0.75 = 7.75 decimal hours. For any number of minutes, the formula is: decimal hours = whole hours + (minutes / 60). This calculator does the conversion automatically - you just read the "decimal hours" output field.
Can I calculate hours between two times that cross midnight?
Yes. Set the overnight toggle to "auto-detect" (the default) or "force next day." When the end time is earlier than the start time, the calculator treats the end as being on the following day. For example, 23:00 to 07:00 is calculated as 8 hours. If both times are within the same calendar day (end is after start), the overnight option has no effect.
How many hours is 9am to 5pm?
From 9:00 to 17:00 is exactly 8 hours (480 minutes). If you take a 30-minute unpaid lunch break, the net worked time is 7 hours 30 minutes, or 7.50 decimal hours. Many standard office schedules use this pattern: 9am to 5pm with a 30-minute break yields 7.5 paid hours per day, or 37.5 hours for a standard five-day week.
What is the difference between gross hours and net hours?
Gross hours is the total time from the moment you clock in to the moment you clock out, including any breaks. Net hours (or paid hours) is what remains after subtracting unpaid break time. If you clock in at 08:00 and out at 16:30 and take a 30-minute unpaid break, gross hours = 8.50 h and net hours = 8.00 h. Payroll uses net hours.