COUNTIF Function with Multiple Criteria (Table of Contents)
- COUNTIF with Multiple Criteria
- COUNTIF Formula with Multiple Criteria
- How to Use COUNTIF Function with Multiple Criteria?
COUNTIF with Multiple Criteria
COUNTIF function helps us to count the cells or calculate the number of a certain value in a list. Sometimes for the business purpose, we need to use multiple criteria for counting.
There can be two ways for multiple counting:
- COUNTIF Function with multiple criteria in the same column.
- COUNTIF Function with multiple criteria in multiple columns.
COUNTIF Formula with Multiple Criteria
Below is the COUNTIF Formula :
The COUNTIF Formula has two arguments i.e. range, criteria.
- Range: The range of cells to count.
- Criteria: This defines the condition that tells the function which cells to count. It can be a number, text string, cell reference, or expression.
Here in this article, we will discuss the COUNTIF Function with multiple criteria in the same column.
As we know that COUNTIF function is a built-in function in excel and it falls under FORMULAS tab. Thus, COUNTIF function can be entered in a cell-like below screenshot:
How to Use COUNTIF Function with Multiple Criteria?
It is very simple and easy to use. Let us understand the working of COUNTIF Function by some COUNTIF Formula example.
We have given some product list:
We need to find out the count of Laptop & Mobile. As these products are in the same column, hence we will use COUNTIF function here.
We have given two conditions, hence the COUNTIF formula will apply as follows:
= COUNTIF(range, criteria1) + COUNTIF(range, criteria2) + …….
Please refer below screenshot:
- Here, we will apply the condition one by one. First will take the range and 1st condition under COUNTIF function. Again will take the same range and 2nd condition under COUNTIF function and so on…
- After applying all the given conditions, sum up all the results to find out the final conclusion.
The final result is:
We have given some product details here. In this example, we will use a COUNTIF function between two numbers.
Here we will calculate, the count of items which is greater than 12 and less than 30.
The COUNTIF formula will apply as follows:
Please refer below screenshot:
- We pass the condition one by one and in end sum all the results.
Hence the final result is:
Let’s take the same product details again.
Here, we will calculate the sum of products who sold out in the month of Jan, Feb & May.
We will apply the COUNTIF formula as follows:
- First, we will select the range of cells from D40:D51 and will pass 1st condition “Jan”.
- Second, we will again select the range of cells from D40:D51 and will pass the 2nd condition “Feb”.
- A third will again select the range of cells from D40:D51 and will pass the 3rd condition “May”.
- After passing all the conditions one by one, in the end, add all the results.
The Final Result is:
Things to Remember about COUNTIF Function with Multiple Criteria
- First, analyze the problem and condition mentioned.
- If the conditions are related to one specific column then will apply the COUNTIF function in a single column as we discussed in the above article.
- If conditions are related to multiple columns, then we use COUNTIFS function which we will discuss in the later article.
This has been a guide to COUNTIF with Multiple Criteria. Here we discuss the COUNTIF Formula with Multiple Criteria and how to use the COUNTIF Function along with practical examples and downloadable excel template. You can also go through our other suggested articles –