Skip to content
Google Sheets

COUNTUNIQUE function in Google Sheets

Counts the number of unique values in a list of specified values and ranges.

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

COUNTUNIQUE syntax and parameters

Two arguments, one required.

  • value1anyRequired

    The first value or range to consider for uniqueness.

  • value2anyRepeating

    [ OPTIONAL ] - Additional values or ranges to consider for uniqueness.

COUNTUNIQUE examples

Formulas you'll actually reuse.

  1. Distinct customers in the orders sheet:

    =COUNTUNIQUE(A2:A200)

    Result38

  2. Distinct customers within one region:

    =COUNTUNIQUE(FILTER(A2:A, B2:B = "West"))

    Result12

COUNTUNIQUE in Excel

No direct equivalent — here's the way around.

Try COUNTUNIQUE in the playground

Edit the example — nothing to install.

Preloaded with the COUNTUNIQUE formula from Example 1 — change anything and watch it respond.

Loading the editor…