Knowing how to count cells with text in Google Sheets **is useful if you want to return the number of cells with text in a dataset.**

##### Table of Contents

Let’s take an example.

Say you have a list with your revenues from 2018 and 2019. There were a few months when there was no revenue at all. Now you need to know how many revenues were in both these years.

**So how do we do that?**

Simple. There are several ways we can count cells with text in Google Sheets and in this guide we will explain all of them. The first one we will explain is the `COUNTA`

function. The `COUNTA`

function is used to return the number of values in a dataset.

## The Anatomy of the COUNTA Function

The syntax (the way we write) the `COUNTA`

function is as follows:

=COUNTA(value1, [value2, value3, ...])

Let’s break this down to understand the syntax of the `COUNTA`

function and what each of these terms means:

`=`

the equals sign is the sign we put at the beginning of any function in Google Sheets.`COUNTA()`

is our function.`value1`

is the first value or range to consider when counting.`value2, value3, ...`

**[optional]**are additional values or ranges to consider when counting.

### ⚠️ A few notes you should know when writing your own COUNTA function in Google Sheets:

- The
`COUNTA`

function is specified as taking a maximum of 30 arguments. - Unlike the
`COUNT`

function that counts only numeric values, the`COUNTA`

function counts all values in a dataset.

## How to Count Cells with Text in Google Sheets Using the COUNTA Function

Let’s take a look at how to count cells with text in Google Sheets using the `COUNTA`

function, step-by-step.

- First, click on the cell where you would want to write your formula. In this guide, we will use
**cell C15**.

- Type the equals sign
**‘=’**and start writing the formula. First, we will write the`COUNTA`

function. After the opening round bracket**‘(‘**, type the range to consider when counting**(B2:C13)**. Close the function with the closing round bracket**‘)’**or hit the**Enter key**on your keyboard.

- If you did everything according to the instructions, the result in
**cell C15**will be**22**.

That is it! Now you know how to use the `COUNTA`

function. The next way to count cells with text in Google Sheets we will explain is by using the `COUNTIF`

function. The `COUNTIF`

function is used to return a conditional count across a range.

## The Anatomy of the COUNTIF Function

The syntax of the `COUNTIF`

function is as follows:

=COUNTIF(range, criterion)

Let’s break down this function, too, so you would better understand what each of these terms means:

`=`

the equals sign is used to start off any function in Google Sheets.`COUNTIF()`

this is our function.`range`

is the range that is tested against`criterion`

.`criterion`

is the pattern or test to apply to the`range`

.

### ⚠️ A few notes you should know when writing your own COUNTIF function in Google Sheets:

- The
`COUNTIF`

function is used only for conditional counts with a single criterion. For multiple criteria, use the`COUNTIFS`

function. - The
**criterion**must be enclosed with the double quotation marks**“”.**

If you would want to know more about how to use the COUNTIF function, you should check the Sheetaki’s website.

## How to Count Cells with Text in Google Sheets Using the COUNTIF Function

Now, let’s take a look at how to count cells with text using the `COUNTIF`

function in Google Sheets, step-by-step.

- First, we should click on a cell to make it active. We will use
**cell C15**.

- Then, to start off the function, we should type the equals sign
**‘=’**. Now type the name of the function, which is now`COUNTIF`

. After the opening round bracket**‘(‘**, we should enter the range to consider when counting. The range is the same as before and is**B2:C13**. However, this time we will not close the function. Just put a comma**‘,’**after the range.

- After the comma, type the
**“<>”**(including the double quotation marks). This means that as long as the cell is not blank, it should be counted. Close the round bracket**‘)’**or press**Enter**on your keyboard, and if you did everything according to the instructions, the result in**cell C15**will be**22**.

You can also use the `COUNTIF`

function in Google Sheets to count cells with specific text. You can even modify it to count cells that do not contain a specific text. he formula will look like this **=COUNTIF(range,”<>criterion”)**. Comparison operators **‘<>’** mean **‘not equal to (the criterion)’**.

That is it! Now you know how to count cells in Google Sheets in a few different ways! You can make a copy of the spreadsheet using the link below and practice some more:

Or you can take a look at the **other Google Sheets formulas** you can use to create even more effective formulas that will help you with your work and save some time, as well 🙂

## 1 comment

That was truly helpful, Thank you.