How to Count Not Blank Cells
(Excel COUNTIF Function)
Are you tired of sifting through endless rows of data in Excel, trying to find the cells that are not blank?
Look no further! 👀
In this step-by-step guide, you learn how to use the COUNTIF function to efficiently count the number of non-blank cells in your spreadsheet.
Say goodbye to manual counting and hello to accurate and efficient data analysis! 💪
You can also download our sample workbook here to practice COUNTIF along the guide.
Table of Contents
Make COUNTIF function count cells that are not blank
Instead of counting the non-empty cells in your data set manually, you can have Excel to do it for you. Wonder how?
By using the COUNTIF function.
It automatically counts the number of all cells containing data in a selected range. Not only does it save you lots of time, but it also increases overall productivity 😀
Let’s see how to use the COUNTIF not blank function to count non-empty cells.
Say, we have the following sample data.

The data set consists of feedback from some customers for a product. As evident, not all customers gave feedbacks.
We want to count the number of not blank cells using the Excel COUNTIF not blank formula.
To do that,
- Select cell C2.
- Add the COUNTIF formula as:
=COUNTIF(

- Enter the range containing the non-empty values.
=COUNTIF(B2:B10)

- Enter the criteria as follows:
=COUNTIF(B2:B10, “<>”&””)

- Press Enter.
Excel will return the result as:

Excel counted all the non-blank cells for us on the range in seconds 🎯
How easy is that? You will be able to master this instantly.
Count cells that are not blank with COUNTA
Similar to the COUNTIF function, there is another function you can use to count cells that are not blank.
You guessed right – it’s the COUNTA function in Excel 😉
Using it is even more simple and easier than COUNTIF. We will use the same sample data as used above.
To use COUNTA to count non-empty cells,
- Select C2.
- Type in the COUNTA formula as:
=COUNTA(

- Enter the range:
=COUNTA(B2:B10)

And voila! It’s done
- Press Enter.
Excel will return the result as:

COUNTA returned 5 showing that there are five non-empty cells in the selected data range.
Pretty easy, no? You can do it too using our free sample workbook 🤓
That’s it – Now what?
In this article, we saw how to count non-empty cells in our spreadsheet using the COUNTIF function. We also saw how to do the same task using the COUNTA function.
Both functions can help you count cells containing data and save you a lot of time. The formulas can be a bit tricky to understand at first. But a couple of tries are all you need to master these functions 🥇
Luckily, similar to COUNTIF and COUNTA, Excel has many other outstanding functions. Our favorites include IF, SUMIF, and VLOOKUP.
You can learn these functions for free in my 30-minute free email course that teaches this and more. You can get it only at the cost of your email address. So sign up now! 🚀
Other resources
Did you like this article? If yes, then you’d love to learn more.
Read similar topics: COUNT in Excel, SUMPRODUCT, Use COUNTIF and COUNTIFS functions.