How to Limit Worked Time to Eight Hours in Excel (Formula Guide)
Question details
The user needs an Excel formula to restrict calculated working hours to a maximum limit of eight hours per day.

- Product
- Excel
- Device & OS
- not provided
- Scenario
- Calculating employee hours or preparing daily timesheets where regular time caps at exactly 8 hours.
- Observed behavior
- Using simple numeric limits like =MIN(8, H7) fails because Excel stores time as a fraction of a 24-hour day, not as whole integer hours, requiring specific fractional or time-string formulas.
Ensure that your source time cells contain valid time values rather than plain text, as Excel calculations rely on proper time formatting to process limits accurately.
Use the MIN Function with a Daily Fraction (8/24)
This is the most robust method to cap hours, relying on Excel's native behavior of treating one day as a value of 1, making 8 hours exactly 8/24.
Because Excel stores dates and times as serial numbers where 1 equals a 24-hour day, simply typing '8' means 8 whole days. To represent 8 hours, you must divide 8 by 24.
The MIN function evaluates your total worked time and the 8-hour limit, returning whichever is smaller.
Click on the cell where you want the capped regular hours to be displayed.
Type =MIN(8/24, H7) into the formula bar, assuming cell H7 contains the total hours worked, and press Enter.
Right-click the cell and select 'Format Cells'. Go to the 'Number' tab, choose 'Custom' from the category list, type [h]:mm in the Type box, and click OK. The brackets ensure hours over 24 display correctly without rolling over.

Use the MIN Function with a Time String
An alternative, highly readable approach is to compare the worked hours directly against a literal time string representing eight hours.
Calculate Work Hours Seamlessly with WPS Spreadsheet
Managing timesheets and complex time calculations is effortless with WPS Spreadsheet. It fully supports advanced time functions, including MIN, and custom formatting rules just like Excel, ensuring accurate payroll and hour tracking.
- 1. Open your timesheet: Launch WPS Spreadsheet and open the document containing your employee time records.
- 2. Input the MIN formula: Select the target cell, type =MIN(8/24, H7) (replace H7 with your actual source cell), and press Enter.
- 3. Apply custom formatting: Press Ctrl+1 to open the Format Cells dialog, navigate to the Custom category, and input [h]:mm to accurately display the hours.

Frequently Asked Questions
Why does =MIN(8, H7) output an incorrect maximum for time?
In Excel, time is calculated as a fraction of a 24-hour day. The integer '8' is interpreted as 8 full days (192 hours), not 8 hours. To specify 8 hours, you must use 8/24 or the string "8:00".
What does the [h]:mm format do in Excel timesheets?
The standard h:mm format resets to zero after 24 hours (like a clock). Placing brackets around the 'h' ([h]:mm) forces Excel to display elapsed time, allowing you to show totals like 45:30 (45 hours and 30 minutes) instead of rolling over to the next day.
How do I calculate overtime hours beyond the 8-hour limit?
To calculate any hours worked over the 8-hour maximum, you can use the formula =MAX(0, H7-8/24) or =MAX(0, H7-"8:00"). This subtracts 8 hours from the total and ensures the overtime result doesn't go below zero if they worked less than 8 hours.




