Count Cells that Do Not Contain in Excel & Google Sheets
Download Example Workbook
Download the example workbook
This tutorial will demonstrate how to count cells that do not contain specific text.
Count Cells that Do Not Contain Specific Text with COUNTIF
The COUNTIF Function counts all cells that meet a certain condition. We can use the COUNTIF Function along with the not equal to sign, <>, and the asterisk wildcard, *, to count cells that do not contain certain text.
In this example, we will count all cells that do not contain the text “Ash”:
=COUNTIF(A2:A11,"<>*Ash*")
As highlighted above, since the cells A5 and A10 start with the word “Ash”, they are not counted.
Count Cells that Do Not Contain Specific Text with COUNTIF in Google Sheets
These functions also work the same way in Google Sheets as well.
=COUNTIF(Range, “<>*Ash*”)