Asset 20 8 2
Does AI recommend your business? Run the free check →

Join 15,000 business owners, marketers and entrepreneurs. The Sunday newsletter you'll be annoyed only arrives once a week.

Article

How to Count Unique Values in Google Sheets (2026)

Type =COUNTUNIQUE(A1:A100) into an empty cell, swapping A1:A100 for your own range, and you'll get the number of different values in that list. It's the quickest way to count unique values in Google Sheets. Just don't expect it to count unique rows across several columns, because that isn't supported.

What COUNTUNIQUE is and what it is not

COUNTUNIQUE counts how many unique values sit in a list of values and ranges you give it. The syntax is COUNTUNIQUE(value1, [value2, ...]), where value1 is the first value or range and anything after it is optional.

It isn't a row counter. Google's help page carries a tip saying that counting unique rows across multiple columns isn't supported, and that's the bit that trips people up.

Count distinct values in a range

  1. Click an empty cell where you want the answer.
  2. Type =COUNTUNIQUE( to start the formula.
  3. Enter your first range or value, for example A1:A100.
  4. Add any further ranges or values after a comma.
  5. Close the bracket and press Enter.

Worked COUNTUNIQUE examples

The first two formulas below are Google's own sample usage, and the notes show what they're doing.

FormulaWhat it looks at
=COUNTUNIQUE(A1:C100)Every value in three columns, treated as one pool of values
=COUNTUNIQUE(1,1,2,3,5,8,13,A2,B6:B9)Typed numbers, one cell and one range, all mixed in the same formula

In that second sample, the typed numbers alone give 6 unique values from 7 entries, because 1 appears twice. Whatever's in A2 and B6:B9 is then counted on top if it's new.

Here's a small example of why rows are different. Say A1:B3 holds London and Red, then London and Red again, then Paris and Blue. There are 2 unique rows, but =COUNTUNIQUE(A1:B3) looks at the individual values, so it finds London, Red, Paris and Blue and returns 4.

When COUNTUNIQUE is the wrong fix

  • You care about whole records spanning columns, not single entries. This function can't judge that, so a multi-column result isn't a record count.
  • You want another kind of count. Google lists COUNTIF, COUNTA, COUNTBLANK, COUNT, DCOUNT and DCOUNTA as the related functions, so check those on its help pages.
  • You're adding numbers up against a condition, not counting. Our SUMIF guide is where you want to be.
  • You're trying to find a value in a table. Go to the VLOOKUP walkthrough instead.

My advice: if your list sits in one column, use COUNTUNIQUE and move on. If you're really after rows, stop and rethink the question before you report that number to anyone.

Work with me

Want AI doing the heavy lifting in your marketing?

I build the systems that handle the boring 80 percent, so you get your week back. Done properly, with the human kept in.

Frequently asked questions

How many ranges can one formula take?

It's specified with a maximum of 30 arguments, but Sheets supports an arbitrary number for this function.

Can I type values straight into the formula?

Yes. Google's sample mixes typed numbers with a cell and a range.

Is value2 required?

No. Only value1 is needed, and everything after it is optional.

Is it the same function as COUNTA?

No, they're separate. Google lists COUNTA as a related function, and COUNTUNIQUE's job is the number of unique values.

What should I enter as value1?

Either a single value or a range. In practice, that's normally the column you're checking.

Published and maintained by the Lilach Bullock team, covering marketing, AI and business growth.
Your buyers are asking AI who to use. Does it say you?

See for free whether ChatGPT, Claude, Perplexity, Gemini and Google name you, and get the plan to become the answer.

Check my AI visibility →
Sundays only

Get the Sunday newsletter.

One email a week. AI experiments, marketing tactics, and the workflows Lilach is building right now in her own business.

Subscribe free

Let’s get your marketing running on AI.

Book a free 30-minute call

We figure out what you need, where AI fits in, and what working together would look like.

Book the call →

Or take the 30-second calculator

You’ll see the hours and the money quietly leaking out of your week, and the three workflows worth building first.

Take the calculator →

Or grab the free AI resource library

Prompt packs, templates, checklists, and swipe files. The exact tools I build for paying clients. Yours, free.

Get the library →
Keep reading

More from the blog.