Excel Conditional Formatting for Overdue Dates by Day Range
Question details
Apply different colors to dates based on how many days overdue they are.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- A worksheet contains due dates that should be grouped into overdue ranges such as 1–29, 30–59, and 60–89 days.
- Observed behavior
- Each overdue date should display the color assigned to its day range, while current and future dates remain unformatted by these rules.
Make sure the due dates are stored as Excel dates rather than text and do not include time values. Identify the first date cell in the range; the examples below use A2.
Create formula-based rules for each overdue date range
Use TODAY() to calculate how many days have passed since each due date and assign a fill color to each range.
Select the date range, such as A2:A100. The formulas below assume A2 is the first cell in the selection.
On the Home tab, select Conditional Formatting > New Rule > Use a formula to determine which cells to format.
Enter =AND(ISNUMBER($A2),$A2>0,TODAY()-$A2>=1,TODAY()-$A2<=29). Select Format, choose a fill color, and click OK to save the rule.
Create another formula rule for each range: 30–59 days: =AND(ISNUMBER($A2),$A2>0,TODAY()-$A2>=30,TODAY()-$A2<=59); 60–89 days: =AND(ISNUMBER($A2),$A2>0,TODAY()-$A2>=60,TODAY()-$A2<=89); 90 or more days: =AND(ISNUMBER($A2),$A2>0,TODAY()-$A2>=90). Choose a different fill color for each rule.
Go to Home > Conditional Formatting > Manage Rules and confirm that each rule applies to the intended date range, such as =$A$2:$A$100.

Highlight overdue date ranges in WPS Spreadsheets
Use formula-based conditional formatting in WPS Spreadsheets to assign colors to due dates according to how many days overdue they are.
- 1. Open your spreadsheet: Open WPS Spreadsheets and select the workbook containing your due dates.
- 2. Select the date range: Select the cells containing the dates, such as A2:A100.
- 3. Create a formula rule: On the Home tab, open Conditional Formatting > New Rule and choose the option to use a formula. For dates 1–29 days overdue, enter =AND(ISNUMBER($A2),$A2>0,TODAY()-$A2>=1,TODAY()-$A2<=29), then choose a fill color.
- 4. Add the other ranges: Repeat New Rule for the 30–59, 60–89, and 90-or-more-day formulas above, selecting a different fill color for each.
- 5. Save the workbook: Check that the rules apply to the selected date range, then use File > Save or Save As to save the workbook.

Frequently Asked Questions
Why are blank date cells not highlighted?
The formulas check that each cell contains a positive number, so blank cells are excluded from the overdue rules.
Will dates due today or in the future receive a color?
No. The first rule starts at one day overdue. Create a separate conditional-formatting rule if you also want to highlight dates due today.
How do I change the overdue ranges or colors?
In Excel, open Home > Conditional Formatting > Manage Rules. Select a rule to edit its formula or format, and adjust its day limits or fill color.
Why does the rule use $A2 instead of $A$2?
The dollar sign fixes the date column, while the relative row number lets Excel check the date in each row. Change A2 to match the first date cell in your selected range.
Will the colors update as the date changes?
Yes. TODAY() returns the current date when the workbook recalculates. In Excel, check Formulas > Calculation Options > Automatic if the colors are not updating.




