COUNT Function – Google Sheets

The COUNT function counts the numeric values in a data set. When all inputs to the function are numbers, it produces the same result as the COUNTA function. However, when the inputs are text or boolean values, the COUNTA function acts differently than COUNT. Get your copy of the template used in this tutorial to follow along.


The COUNT function returns the number of numerical values in a data set.


=COUNT(value1, [value2, ...])

  • value1 – The first number or range to consider while counting.
  • value2, … – [OPTIONAL] Additional numbers to consider.


Example 1 – Counting Numbers

Regular numbers being counted
Just Numbers

Four numerical values are in the image above and the formula returns the number 4. Counting numbers is the most straightforward use of the function.

Example 2 – Counting Blanks vs. Counting Zeroes

The COUNT function will treat blanks differently from zeroes as we move into the following example. A blank cell does not have a data type, but 0 is a number.

Zeroes and blanks being counted differently by the COUNT function
Blanks vs. Zeros

While 0 is a number, you may not intend to count it. If you only want to count numbers greater than zero, you may consider using a formula such as =COUNTIF(B2:B5,">0").

What if we had a mix of text and numbers?

Example 3 – Counting Text and Numbers

Different data types being counted
Mixed Data Types

The COUNT function only sees one number in the range (A2:A5). As shown in the previous example, the function does not count the blank. Also, the function ignores the text values of Nice day and 5 stars. The text value 5 stars contains the number 5, but having the text stars after the five converts the value to text.

If you want to find the amount of text and number values while ignoring the blanks, consider the COUNTA function.

Example 4 – Counting Dates

Now let’s move on to dates. Remember, spreadsheets treat dates the same as numbers in a spreadsheet.

Counting dates
Valid and Invalid Dates

The trick with dates is that they need to be valid to be considered a number. In the example above, Google Sheets does not recognize Feb 20th as a valid date. You can tell because it is left-aligned, which is how spreadsheets show text values. Also, for a spreadsheet to treat a date as a number, it must have a year.

Numbers and text are relatively common in spreadsheets, but you can also have boolean values.

Example 5 – Boolean Values

Boolean values only have two options – TRUE or FALSE.

Boolean values counted as zero
Boolean Values

So, boolean values just aren’t counted, right? Not so fast. The COUNT function disregards them if they are in cells referenced by the COUNT function but counts them if they are input directly.

Using the COUNT function with directly input Boolean values
Directly Input

It makes no sense, right?

Live Examples in Sheets

Go to this spreadsheet for examples of the COUNT functions shown above that you can study and use anywhere you would like.


  • COUNT ignores blank cells.
  • The COUNT function counts text as 0.
  • Consider using the SUBTOTAL function if you have multiple counts in one column.

Leave a Comment