Display a Holiday Check Mark Using Dates in Excel
Question details
Display a check mark when a date is in a holiday table and values exist for the preceding and following dates.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- A worksheet contains dates and associated values, while a second sheet lists holiday dates.
- Observed behavior
- The desired result is a check mark only when the worksheet date matches a holiday and both adjacent calendar dates have nonblank values.
Check that Sheet1 column B and Sheet2 D3:D11 contain real Excel dates from the intended year, without time components. This example checks values in Sheet1 column C and uses E5 for the result; adjust the references to match your workbook.
Use COUNTIF and COUNTIFS to display the holiday check mark
Use a formula to test the holiday date and check for nonblank values on both adjacent calendar dates.
On Sheet1, select E5 and enter =IF(AND(ISNUMBER($B5),COUNTIF(Sheet2!$D$3:$D$11,$B5)>0,COUNTIFS($B:$B,$B5-1,$C:$C,"<>")>0,COUNTIFS($B:$B,$B5+1,$C:$C,"<>")>0),"✓","").
Drag the fill handle from E5 down column E. Each row checks its date in column B against the holiday list and looks for nonblank column C values on the previous and next dates.
Select E5:E100, then choose Home > Conditional Formatting > New Rule. Choose a formula-based rule, enter =$E5="✓", and select a font or fill color.

Create the holiday check mark in WPS Spreadsheets
Use COUNTIF and COUNTIFS in WPS Spreadsheets to check the holiday list and adjacent-day values, then highlight the resulting check marks.
- 1. Open the workbook: Open the Excel workbook in WPS Spreadsheets and locate the dates and values on Sheet1 and the holiday list on Sheet2.
- 2. Enter the check formula: Select Sheet1 cell E5 and enter =IF(AND(ISNUMBER($B5),COUNTIF(Sheet2!$D$3:$D$11,$B5)>0,COUNTIFS($B:$B,$B5-1,$C:$C,"<>")>0,COUNTIFS($B:$B,$B5+1,$C:$C,"<>")>0),"✓",""). Adjust the references if your data is elsewhere.
- 3. Fill the formula down: Drag E5's fill handle down alongside the dates you want to check.
- 4. Format the results: Select the result cells and use Home > Conditional Formatting to create a formula rule such as =$E5="✓" and choose a highlight color.

Frequently Asked Questions
Why does a holiday date not produce a check mark?
Check that the date appears in Sheet2 D3:D11 and that Sheet1 column C has a nonblank value for both the previous and next calendar dates. Also verify that the dates are real dates from the same year and contain no time components.
Can I check for a specific value instead of any nonblank value?
Yes. In each COUNTIFS expression, replace the criterion "<>" with the value to match, such as "Approved", or with a reference to a cell containing that value.
Does the formula check working days or calendar days?
It checks calendar days by subtracting and adding 1 to the date in B5. Weekends and holidays are not skipped.
Can conditional formatting add the check mark by itself?
The conditional formatting rule in this example highlights an existing check mark; the formula in column E produces the mark. Select the result cells and use Home > Conditional Formatting to apply the highlight.




