How to calculate comp time in Excel
At a public employer, overtime may be banked as compensatory time ("comp time") instead of paid in cash. Private employers can't do this under federal law. Here is the rule, and a spreadsheet that tracks each person's comp balance week by week.
A how-to, not legal advice. Your agency's policy and any union contract decide who earns comp time.
The rule in plain words
Under the Fair Labor Standards Act, a public employer may give comp time instead of overtime pay (29 U.S.C. 207(o); 29 CFR 553.20 to 553.28):
- 1.5 hours of comp time for each overtime hour (U.S. Department of Labor Fact Sheet #7). Overtime is hours worked over 40 in the workweek. Police and fire can use other work periods, not covered here.
- Only with an agreement made before the work. It can be a union contract, a written policy the employee accepted, or, for employees hired before April 15, 1986, a regular practice in effect on that date (29 CFR 553.23(a)). No agreement means overtime is paid in cash.
- A cap on the balance: 240 hours, or 480 hours for public safety, emergency response and seasonal work (29 U.S.C. 207(o)(3)(A); which jobs count as public safety, emergency response and seasonal work: 29 CFR 553.24). Once the balance is at the cap, further overtime must be paid in cash.
- Comp time used is time off, not hours worked, so, like vacation, it does not count toward the 40 hours that trigger overtime.
- Leaving the job: unused comp time is paid at the higher of the employee's average regular rate over their last 3 years or their final regular rate (29 CFR 553.27(b)).
Build the tracker
Make a tab named Comp with one row per employee per week:
| A | B | C | D | E | F | G | H | I |
|---|---|---|---|---|---|---|---|---|
| Employee | Week starting | Hours worked | Comp used (h) | Starting balance | Overtime hours | Comp earned | OT paid in cash (h) | Ending balance |
Put the cap where you can see it, for example K1 = 240. Formulas for row 2, filled down:
- F2, overtime hours:
=MAX(0, C2-40) - E2, starting balance: for a person's first week, type the balance from your records. Later weeks take the previous week's ending balance. If each person's weeks are listed together in date order:
=IF(A2=A1, I1, 0), replacing 0 with their opening balance the first time. - G2, comp earned (banked, up to the cap):
=MIN(F2*1.5, MAX(0, $K$1-(E2-D2))) - H2, overtime paid in cash (what didn't fit under the cap):
=F2 - G2/1.5 - I2, ending balance:
=E2 - D2 + G2
Add a guard column for comp used beyond the balance: =IF(D2>E2, "Used more than balance", ""). Leave employees without a comp agreement off this tab: their overtime is paid in cash.
Worked example
Ana starts the week with 230 hours banked, uses none, and works 48 hours.
- Overtime is 8 hours, which would earn 12 comp hours.
- Room under the 240 cap is 10 hours, so 10 comp hours are banked (6.67 overtime hours' worth).
- The other 1.33 overtime hours are paid in cash at 1.5 times her regular rate.
- Ending balance: 240.
The tracker subtracts comp used before adding comp earned in the same week. If your policy counts them in a different order, change the formula and write the rule at the top of the sheet.
Common mistakes
- Hours worked includes vacation or comp used. Keep those in their own column; only hours actually worked go in column C.
- Weeks averaged across a pay period. A biweekly pay period still has two separate workweeks. 45 hours one week and 35 the next is 5 hours of overtime, not zero (Fact Sheet #23).
- No record of who agreed to comp time. Keep the agreement list next to the tracker.
- The cap ignored. Overtime past the cap must be paid in cash.
Doing this every week without formulas
If your punches are already in a spreadsheet (a time-clock export, a Microsoft Forms or Google Forms clock-in, or typed timesheets), WeekClose does this for you in Excel or Google Sheets. It reads the punch rows, works out each workweek's overtime, banks comp time for the employees you mark "Comp", applies the 240 or 480 hour cap, shows overtime that must be paid in cash, and carries balances forward. Comp time is part of WeekClose Pro; try it free on sample punches.
Sources: 29 U.S.C. 207(o); 29 CFR 553.20 to 553.28 (ecfr.gov); U.S. Department of Labor Fact Sheet #7, State and Local Governments under the FLSA; Fact Sheet #23, Overtime Pay. Checked November 2026.