COUNTUNIQUE Function in Google Sheets: Explained | LiveFlow (2024)

In this article, you will learn how to use the COUNTUNIQUE formula in Google Sheets.

What does the COUNTUNIQUE formula do in Google Sheets?

This formula allows you to count the number of cells with any duplicates excluded. If there are some duplicates of a particular value in a data set, you apply this formula, and the number of the specific values is counted as one.

How to use the COUNTUNIQUE formula in Google Sheets

  1. Type “=COUNTUNIQUE” or go to “Insert”“Function” (or directly navigate to the “Functions” icon) “Math”“COUNTUNIQUE”.
  2. Select a range or an array in which you want to count the number of distinctive values.
  3. Press the “Enter” key.

COUNTUNIQUE Function in Google Sheets: Explained | LiveFlow (1)

The generic syntax is as follows:

=COUNTUNIQUE(value1, [value2, …]).

Value1: This argument should be a cell, range, or array.

Value2: If you need to select other ranges, you can add as value2, value3, ….

Note

  1. The COUNTUNIQUE function counts the number of unique values. So, even when a specific value appears more than once in a data set, the particular value is measured only once.
  2. The function does not count the number of entirely blank cells, though it counts the number of cells containing only whitespace(s).
  3. Ensure all values that you want to count don’t include hidden text such as ““ or an apostrophe. For example, if a cell input is “‘7”, it looks like “7”.

The following picture how the formula works. As you can see, while the total number of cells is eight in the chosen range, the function returns five. Why does this happen? - (i) The COUNTUNIQUE formula counts the redundant items (ones highlighted) only once for each item; and (ii) it doesn’t count the number of emply cells.

COUNTUNIQUE Function in Google Sheets: Explained | LiveFlow (2)

Does the COUNTUNIQUE function count blank cells?

As explained above, it does not count the number of entirely blank cells. If you need to calculate the number of empty cells, you should use the COUNTBLANK formula.

COUNTUNIQUE Function in Google Sheets: Explained  | LiveFlow (2024)

FAQs

COUNTUNIQUE Function in Google Sheets: Explained | LiveFlow? ›

The COUNTUNIQUE function counts the number of unique values. So, even when a specific value appears more than once in a data set, the particular value is measured only once. The function does not count the number of entirely blank cells, though it counts the number of cells containing only whitespace(s).

How does Countunique work in Google Sheets? ›

COUNTUNIQUE is a function in Google Sheets that counts the number of unique values in a specified range or list of values. For example, if you have a column of data with duplicate values, and you want to know how many unique values there are, you can use the COUNTUNIQUE function.

How do you use Countunique formula? ›

Suppose we have a list of names in column A, and we want to count the number of unique names. We can use the CountUnique function as follows: =COUNTUNIQUE(A2:A10). This will return the number of unique names in the range A2:A10. Another example could be counting the number of unique products sold in a store.

What is the difference between Countunique and count? ›

To count unique values, use COUNTUNIQUE . To count only numeric values use COUNT .

What is the unique count query in Google Sheets? ›

What function counts unique values in Google Sheets? The COUNTUNIQUE function in Google Sheets counts the number of unique values in a range. Use the following formula: =COUNTUNIQUE(range).

What is the difference between Countuniqueifs and Countifs? ›

It is similar to the COUNTIFS function, which also accepts multiple criteria. However, COUNTUNIQUEIFS counts unique values, whereas COUNTIFS counts all values that meet the specified criteria.

Does Countunique count blanks? ›

As explained above, it does not count the number of entirely blank cells. If you need to calculate the number of empty cells, you should use the COUNTBLANK formula.

How do you count unique values only? ›

Count the number of unique values by using the FREQUENCY function. The FREQUENCY function ignores text and zero values. For the first occurrence of a specific value, this function returns a number equal to the number of occurrences of that value.

How do you check for unique values in Google Sheets? ›

To use the UNIQUE function in Google Sheets, simply type =UNIQUE(range) where 'range' is the cell range you want to extract distinct values from.

How do I count how many times something appears in Google Sheets? ›

The Google Sheets COUNTIF function is often the quickest way to count how many times an item appears in a defined cell range. The function's straightforward but powerful capabilities simplify your work in Google Sheets. And you can also automate your dashboards and workflows in Google Sheets with Coefficient.

How do I use Countif with unique? ›

The COUNTIF function counts how many times each individual value appears in the specified range. In this example, COUNTIF(A2:A10,A2:A10) returns the array {1;2;2;1;2;2;2;1;2} . The IF function evaluates each value in the array returned by COUNTIF, keeps all 1's (unique values), and replaces all other values with zeros.

What does Countunique mean in Excel? ›

Counts the number of unique values in a list of specified values and ranges. COUNTUNIQUE for BigQuery. Counts the number of unique values in a data column.

How does count distinct work? ›

The COUNT DISTINCT function returns the number of unique values in the column or expression, as the following example shows. SELECT COUNT (DISTINCT item_num) FROM items; If the COUNT DISTINCT function encounters NULL values, it ignores them unless every value in the specified column is NULL.

How to use countunique in Google Sheets? ›

Example
  1. Step 1: Select the Cell Where You Want to Place the Result. ‍ Select the cell where you want the result to appear. ...
  2. Step 2: Enter the Formula =COUNTUNIQUE( Add formula to selected cell in Google Sheets. ‍
  3. Step 3: Select The Range Where You Want to Count. ‍ ...
  4. Step 4: Close the Function With Closing Parenthesis. ‍

How do I count the number of entries in Google Sheets? ›

Using the COUNT Function

Choose the Destination Cell: Click on the cell where you want the row count to appear. Input the COUNT Formula: Type =COUNT(B:B) for counting only numeric values within a column. Replace B:B with the column containing the numbers you want to count.

How do I remove duplicates in Google Sheets? ›

Remove rows with repeat data
  1. On your computer, open a spreadsheet in Google Sheets.
  2. Select the data range that you'd like to remove duplicates in. ...
  3. At the top, click Data Data cleanup. ...
  4. Select which columns to include, and whether or not the data has headers.
  5. Click Remove duplicates.

How does unique work in Google Sheets? ›

Returns unique rows in the provided source range, discarding duplicates. Rows are returned in the order in which they first appear in the source range.

How do dropdowns work in Google Sheets? ›

You can add a dropdown list to a cell (or to a range of cells), and when you or another person with access to your spreadsheet clicks the cell, a dropdown will open that shows a list of numbers or words that they can select. The number or word that's selected will then appear inside the cell.

How to countif unique? ›

In this case, you can use a combination of SUM, IF and COUNTIF functions to count unique values in Excel. To count unique values, enter the formula =SUM(IF(COUNTIF(range, range)=1,1,0)) in the desired cell. The range denotes the starting cell and the ending cell.

How does Google Sheets COUNT work? ›

COUNT counts all numeric values in a dataset, including those which appear more than once. To count unique values, use COUNTUNIQUE . COUNT counts only numeric values; text values are ignored.

Top Articles
Latest Posts
Article information

Author: Manual Maggio

Last Updated:

Views: 5468

Rating: 4.9 / 5 (49 voted)

Reviews: 88% of readers found this page helpful

Author information

Name: Manual Maggio

Birthday: 1998-01-20

Address: 359 Kelvin Stream, Lake Eldonview, MT 33517-1242

Phone: +577037762465

Job: Product Hospitality Supervisor

Hobby: Gardening, Web surfing, Video gaming, Amateur radio, Flag Football, Reading, Table tennis

Introduction: My name is Manual Maggio, I am a thankful, tender, adventurous, delightful, fantastic, proud, graceful person who loves writing and wants to share my knowledge and understanding with you.