Counting Cells Excluding Specific Values in Excel

Counting Cells Excluding Specific Values in Excel. Learn how to tally cells that don’t match multiple criteria in Excel. In this guide, we’ll explore various methods to count data based on specific conditions within an array, focusing on ignoring certain values. Let’s delve into three different approaches to accomplish this task effectively:

Counting Cells Excluding Specific Values in Excel

Method 1: Using SUMPRODUCT, MATCH, and ISNA Functions

This method involves a formula that employs MATCH to identify the values to be excluded, ISNA to catch errors, and SUMPRODUCT to sum the resultant values.


= SUMPRODUCT ( -- ( ISNA ( MATCH ( range, values, 0))))


Consider a scenario with a list of fruits and vegetables. To count only the fruits excluding vegetables:

= SUMPRODUCT ( -- ( ISNA ( MATCH (fruits , vegetables , 0 ) ) ) )

Method 2: Utilizing COUNTIFS Function

This technique utilizes COUNTIFS to count cells excluding specific values in the range.


= COUNTIFS ( fruits , "<>" & D3, fruits , "<>" & D4 , fruits , "<>" & D5 )


The formula checks the range against individual values and returns the count of cells not matching those values.

Method 3: Leveraging COUNTA Function

This method involves calculating the count of cells with values in the range and then subtracting the count of specific values from it.


= COUNTA (fruits) - SUMPRODUCT ( COUNTIF ( fruits , vegetables ) )


COUNTIF tallies cells in “fruits” containing “vegetables,” and COUNTA calculates the count of non-empty cells. The difference yields the count of cells (fruits) excluding specified values (vegetables).

Each method offers a distinct approach to counting cells based on specific criteria, providing flexibility for diverse scenarios in Excel. Explore these methods further to master counting techniques that suit your needs.

Have questions or feedback? Feel free to share your thoughts or queries regarding these Excel count functions.

We will be happy to hear your thoughts

Leave a reply
Compare items
  • Total (0)
Shopping cart