How-to · Google Sheets for Mac
How to count unique values in Google Sheets on Mac: formulas and steps for Chrome
To count unique values in Google Sheets on a Mac, type =COUNTUNIQUE(A2:A100) into an empty cell and change the range to match your data. Google Sheets runs in your browser, so you do this in Chrome or another browser, and the steps are the same as on Windows.
Quick answer
- Type =COUNTUNIQUE(A2:A100) in an empty cell to count the unique values in that range.
- COUNTUNIQUE counts each distinct value once, so repeats do not add to the total.
- To delete repeats instead, use Data > Data cleanup > Remove duplicates, which removes rows.
- Google's help page does not say whether counting is case sensitive, so test your data first.
- Google's pages do not describe a native Mac app, so you use Sheets in a browser.
What you need
- A Google account with edit access to the spreadsheet
- Chrome or another browser on your Mac
- A column of values, with the heading in row 1
- Google Sheets opened at sheets.google.com
How to Count unique values in a Google Sheets column on Mac in Google Sheets on a Mac
Open your sheet in a browser
Go to sheets.google.com in Chrome and open the spreadsheet. Google Sheets runs in the browser, so there is no separate app to launch first.
Tip: Any browser can open the same page. The menu names below come from Google's help pages.
Pick an empty cell for the answer
Click an empty cell where the count should appear. Choose a cell outside the list, such as the cell next to your heading.
Tip: Keep the answer outside the range you count. Otherwise the formula may refer to itself.
Type the COUNTUNIQUE formula
Type =COUNTUNIQUE(A2:A100), replacing A2:A100 with your own range. The equals sign tells Sheets that the text is a formula. The closing bracket ends the function.
Tip: You can drag across the cells with the mouse instead of typing the range. The range fills in as you select.
Confirm the formula
Return
Press Return to confirm. The cell shows the number of unique values. If you see an error, check the range spelling and the closing bracket.
Tip: If the result looks odd, press ⌘ z to undo the entry and try again.
Check the count with a small sample
Look at about ten rows and count the distinct values by hand. Compare your count with the formula. If they match, the range is right.
Tip: Type two values that differ only by capital letters in empty cells to test case.
Test a multiple column range
Google's help page says counting unique rows across multiple columns is not supported. Try a two column range on a small sample before you rely on the result.
Tip: Write down the range you tested, so you can repeat the check later.
Find Remove duplicates with Tool finder
⌥ /
Select your range first. Then press ⌥ / and type Remove duplicates. Tool finder lists the matching command, so you can choose it without hunting through the menus.
Tip: Tool finder was called Search the menus in older Google help pages.
Open Data cleanup and choose Remove duplicates
Click Data in the menu bar. Choose Data cleanup, then Remove duplicates. In the dialog, pick the columns to check and say whether the data has headers.
Tip: Selecting one cell inside a range removes duplicates from the whole range, according to Google's help page.
Undo a removal that went wrong
⌘ z
Press ⌘ z right after the change to bring the rows back. For changes made earlier, use revision history, which has its own guide on this site.
Tip: Undo works best right after the change. Make a copy of the sheet first if the list matters.
Count unique values with COUNTUNIQUE
COUNTUNIQUE is the function built for this job. Google's help page gives its syntax as COUNTUNIQUE(value1, [value2]), where value1 is required. Extra values are optional, so you can add more ranges after the first one.
In practice you pass one range. A range is a block of cells, written as the first cell, a colon, and the last cell. A2:A100 means cells A2 down to A100. Row 1 stays out because it usually holds the heading.

Say your fruit names sit in column A, from A2 to A100. Some names repeat. COUNTUNIQUE returns how many different names exist, not how many rows the list has.
The gap between those two numbers shows how much repetition is in the list. A list with many repeats gives a small answer. A list where every name is different gives the same answer as the row count.
Count unique values in a column, step by step
The steps below use one column. They work the same way for any column, as long as the formula points at the right range. Follow them in order the first time, then reuse the formula whenever the list changes.
Why the count can differ from what you expect
Google's COUNTUNIQUE help page does not say whether counting is case sensitive. It also does not say how blank cells or errors are handled. That leaves three checks you can run yourself.
First, test case. Type Apple in one empty cell and apple in another. Then run COUNTUNIQUE over those two cells. If you see two, case matters. If you see one, it does not.
Second, test blanks. Empty cells at the bottom of a range can change the answer. Narrow the range to the rows that hold data, then compare the answer with a count by hand.
Third, test spaces. A value with a trailing space can look identical to one without it. The count can treat them as different values, so check for stray spaces.
- Extra spaces at the start or end of a value. Trim them first.
- A range that stops early, such as A2:A50 when the list runs to row 100.
- A header counted as data because the range starts at row 1.
- Nonbreaking spaces, which Trim whitespace does not remove.
Trim spaces and clean the list before you count
Google's cleanup tools live under Data > Data cleanup. Trim whitespace removes extra leading, trailing, and excessive spaces. Nonbreaking spaces are not trimmed, so look for them if the count still seems high.
Run Trim whitespace on the range before you count. It changes the cells, so keep a copy of the sheet if you need the original text.
Remove duplicates in Google Sheets on Mac
Counting and deleting are different jobs. COUNTUNIQUE leaves your data alone. Remove duplicates deletes the repeat rows from the range you select.
Google's help page gives the path as Data > Data cleanup > Remove duplicates. Google says cells count as duplicates when their values match, even if formatting or formulas differ. Google also says letter case does not make rows different in this command.
That rule is for Remove duplicates only. It does not tell you how COUNTUNIQUE handles case, so run your own test before you compare the two results.
| Method | What it does | Changes your data |
|---|---|---|
| COUNTUNIQUE | Counts distinct values in a range | No |
| Remove duplicates | Deletes repeat rows from the selected range | Yes, rows are removed |
| Trim whitespace | Removes extra leading, trailing, and excessive spaces | Yes, the text changes |
Install Google Sheets on your Mac
Google's pages do not describe a native Mac app for Sheets. Google's product page says you can create, view, and edit spreadsheets from a phone, tablet, or desktop. It also says you can work without an internet connection.
If you want a Dock icon, Chrome can install the web app. A third-party guide from The Bricks, dated February 20, 2025, describes the route. Go to sheets.google.com, then click the install icon in the address bar.
Or open the three dot menu, choose Save and Share > Install Google Sheets, click Install, and drag the app to the Dock from Applications or Launchpad.
Safari works differently. File > Add to Dock pins the web page to the Dock. The same guide notes that Safari only pins the page, so it is not a full install.
Google Sheets shortcuts on Mac
Google's shortcut page lists a small set of Mac keys. Show common keyboard shortcuts is ⌘ /. Tool finder, which used to be called Search the menus, is ⌥ /.
Use Tool finder when you know a command's name but not its menu. Type Remove duplicates, pick the match, and the command runs from the list.
Undo is ⌘ z. Find is ⌘ f. Paste values only is ⌘ ⇧ v. Undo is the fastest fix when a removal goes wrong.
Google's page lists no shortcut for Remove duplicates or Data cleanup. Use the Data menu or Tool finder for those commands.

Mistakes people make when counting unique values
The most common mistake is the range. A formula that stops at row 50 misses every row below it. Scroll to the bottom of the list and check the last row before you trust the number.
The second mistake is counting the header. If the range starts at row 1, the heading becomes one more value. Start at row 2 to keep it out of the count.
The third mistake is expecting a list. COUNTUNIQUE returns one number. It does not show you the values. If you need the values, sort the column and read them down, or remove duplicates in a copy.
The fourth mistake is editing a shared sheet. Removing duplicates changes the file for everyone with edit access. Check with your team before you run it on a shared file.
Limits to know for large sheets
20 million
cells per Google Sheets spreadsheet, with a 100MB cap
Google Drive Help: file size and format limits500k
rows per Connected Sheets extract, with a 5 million cell cap
Google Drive Help: file size and format limitsGoogle's Drive limits page says a Google Sheets spreadsheet holds up to 20 million cells or 100MB. Connected Sheets extracts are capped at 500k rows or 5 million cells.
For most lists, these limits never matter. If your list is near them, count a smaller range first, then split the file. Google's COUNTUNIQUE page lists a 30 value maximum, but it also says Sheets accepts more, so test big formulas first.
Next steps after you count
Once you have the count, you may want to sort, filter, or summarize the list. These guides cover those steps for Google Sheets on Mac: sort data by column, filter a range, and SUMIF.
If you want to remove repeated rows for good, read the duplicate rows guide before you run the menu command. It covers the same command with more fixes.
Google Sheets shortcuts for this on Mac
| To do this | Press |
|---|---|
| Show common keyboard shortcuts | ⌘ / |
| Tool finder (formerly Search the menus) | ⌥ / |
| Undo | ⌘ z |
| Find | ⌘ f |
| Paste values only | ⌘⇧ v |
If it does not work
- The count is higher than the unique names you see
- Check for extra spaces with Data > Data cleanup > Trim whitespace, run it on a copy, then count again. Nonbreaking spaces stay, so look for them separately.
- The count does not match your hand check
- Look at the range first. Make sure it starts at row 2 and reaches the last row. Then test case with two cells that differ only by capital letters.
- Data cleanup or Remove duplicates is missing
- Select a range first. If the Data menu shows no edit commands, you may have view-only access. Ask the file owner for edit access.
- Remove duplicates removed more rows than expected
- Google matches values and ignores letter case, formatting, and formulas. Press ⌘ z right after the change, then check the columns you picked in the dialog.
- Tool finder does not open
- Click into the sheet once, then press ⌥ /. The shortcut needs the sheet to be the active part of the page.
Faster with Lazur
Do it faster: ask Lazur while you are in Google Sheets
Hold ⌥ ⌘ and say what you want. Lazur sees your Google Sheets window. Lazur draws a circle and a label around the button or menu you need.
- 1
Hold ⌥⌘ and talk
- 2
Lazur draws a circle and a label around the button or menu you need.
- 3
You stay in Google Sheets. Nothing to copy into a chat window.
Free for 3 days, then $18/month. Download for Mac
You say“Where is the Data cleanup menu?”
Lazur · points at itLazur draws a circle and a label around Data cleanup, so you can find it on the Data menu.
Questions people ask
Is there a native Google Sheets app for Mac?
Google's product pages describe Sheets as a web app. They do not mention a native Mac app. You can install the web app from Chrome, which adds it to the Dock. Safari only pins the web page.
Does COUNTUNIQUE count letter case?
Google's help page does not say. Test with two cells that differ only by case, such as Apple and apple. Two results mean case matters. One result means it does not.
Does COUNTUNIQUE ignore blank cells?
The help page does not say how blanks are handled. Narrow the range to the rows that hold data, then compare the answer with a count by hand.
Can COUNTUNIQUE count unique rows across two columns?
Google's help page says counting unique rows across multiple columns is not supported. Test your exact range on a small sample before you rely on the answer.
Will Remove duplicates delete my data?
It removes the repeat rows in the range you select. Copy the sheet first. Use undo right away if the result is wrong, or check revision history for older changes.
Does Remove duplicates care about capital letters?
Google says duplicates are matched on value, ignoring letter case, formatting, or formulas. So Apple and apple count as duplicates in that command.
What is the size limit for a Google Sheets file?
Google's Drive limits page says up to 20 million cells or 100MB per spreadsheet. Connected Sheets extracts are capped at 500k rows or 5 million cells.
Why is my count higher than the unique names I see?
Hidden spaces, a range that misses rows, or a header inside the range can all push the count up. Trim spaces and check the range first.
Sources
- COUNTUNIQUE - Google Docs Editors Help · Google · checked 2026-11-07
- Split text, remove duplicates, or trim whitespace - Google Docs Editors Help · Google · checked 2026-11-07
- Keyboard shortcuts for Google Sheets - Google Docs Editors Help · Google · checked 2026-11-07
- Google Drive file size and format limits - Google Drive Help · Google · checked 2026-11-07
- Google Sheets - Google Workspace · Google · checked 2026-11-07
- How to Add Google Sheets to Desktop Mac Using AI - The Bricks · The Bricks · checked 2026-11-07
Try Lazur free for 3 days
Hold a key and ask. Lazur sees your screen, points at the button and talks you through it, in any Mac app. No credit card.