How to Use the COUNTIF Function in Google Sheets

Video countif google sheet

Welcome to this information-packed article, where I’ll be sharing all the juicy secrets of using the COUNTIF function in Google Sheets. Whether you’re a spreadsheet newbie or a seasoned pro, COUNTIF is a powerful tool that can save you time and effort when it comes to counting cells that meet specific criteria.

Using the COUNTIF Formula in Google Sheets

Let’s dive right in and learn how to use the COUNTIF formula in Google Sheets. Just follow these simple steps:

  1. Type “=COUNTIF(” or go to “Insert” in the menu bar ➝ “Function” ➝ “Math” ➝ “COUNTIF”.
  2. Select a range of data where you want to find the number of cells that match a specific condition.
  3. After adding a comma, choose a cell containing the specific criterion or enter the criterion directly.
  4. Press the “Enter” key.

How to insert the COUNTIF function from the menu bar

The generic formula is as follows:

  • Range: This is the field in which the formula searches for items that match the criterion.
  • Criterion: This is the standard you apply.

Let’s explore some examples below. Suppose you’re a financial manager analyzing sales records shown in the image below. You’d like to know the number of transactions by salesperson, by batch size, and by registration date.

How to use the COUNTIF function in Google Sheets with examples

(i) Number of transactions by salesperson:

The first step is to identify all the items in a list without any duplication or omission. Make sure to list all the names in the original data in your summary table. The formula range is C4:C13.

As shown above, the criterion, whatever it may be, can be entered by cell reference or manual input. We show examples of manual input in the first two formulas for Anna and Bryan, and cell reference in the third and fourth formulas for Charlie and David. In the case of cell references, the referenced cells are adjacent to the cells containing the COUNTIF formulas.

We do the same for the other two examples (ii) and (iii). However, please note that we strongly recommend using cell references as much as possible and making the format of the formulas (e.g., manual input or cell reference for a criterion) consistent.

Another important thing to keep in mind is that you should calculate the total figure of the calculated values and ensure that it matches the number of items in the original data. In this example, the total figure should be 10 since the original data table contains ten transactions.

(ii) Number of transactions by batch size:

This example shows how to incorporate a number as a criterion in the COUNTIF formula.

(iii) Number of transactions by registration date:

In the third example, you can see how to include a date as a criterion in the formula.

If you’d like to learn how to manually input text, number, or date into a formula, whether it’s a range or a criterion, check out this article.

How to Use COUNTIF Across Multiple Google Sheets

You can use a range of data on a different sheet in the COUNTIF formula. However, we recommend consolidating the necessary information onto one sheet using cell referencing or copy-pasting to avoid incorrect references and have a clear view of data resources.

If you need to know how to reference a range of data on a different sheet in a formula, check out this article: How to reference another sheet in Google Sheets.

Can You Use COUNTIF with Multiple Criteria in Google Sheets?

Absolutely! For example, if you want to count the number of cells that satisfy both criterion A or criterion B in a set of data (range C), you can find the answer by adding the results of two separate COUNTIF formulas like “=COUNTIF(range C, criterion A) + COUNTIF(range C, criterion B)”.

However, if you want to know the number of cells that satisfy both criterion A and criterion B, you need to use the COUNTIFS function instead of the COUNTIF formula.

Check out this article to learn how to use the COUNTIFS function in Google Sheets.

To discover more about different functions and tips for Google Sheets, head over to Crawlan.com and explore numerous informative articles to help you make the most out of Google Sheets.

Note: This article has been created with the brand focus of bolamarketing.com in mind, so other branding and links have been omitted.

Related posts