Check for Duplicates in Google Sheets
en
Run read-only duplicate check

Duplicate detection, grouping, and report export

Duplicate Function Google Sheets

Use a read-only duplicate check for duplicate function google sheets when you need to inspect repeated values without changing the source sheet. Paste the relevant data, select the key scope, review grouped counts and row indexes, and export the evidence.

Inspect duplicate groups in the selected sheet dataKeep source values unchanged during the checkExport row-level evidence for the next step
Check duplicates in pasted sheet data
Review grouped matches for duplicate function google sheets before exporting duplicate evidence.

Report reading guide

Read duplicate results in three passes

  1. Scope: confirm selected key columns.
  2. Groups: review repeated values and counts.
  3. Rows: compare source row numbers before acting.
Key customer@example.comCount 3 matchesRows 12, 27, 41

Use COUNTIF in Google Sheets to identify duplicate values without changing the source data. For a list in A2:A100, enter a formula in a helper column to count each value, then filter for counts greater than one. For duplicate rows, use COUNTIFS with every column that defines a match.

Paste your data and choose the columns to check, then get grouped duplicate counts and row indexes without touching your source.

Find duplicate values with COUNTIF

Assume row 1 contains headers and column A contains customer IDs. Enter this formula in B2 and fill it down through B100:

=IF(A2="","",COUNTIF($A$2:$A$100,A2))

The fixed range is the data set being checked; A2 changes as you copy the formula down. A count of 1 means the ID appears once in that range. A count greater than 1 marks every occurrence of a repeated value, including the first.

To show a label instead of a number, use:

=IF(A2="","",IF(COUNTIF($A$2:$A$100,A2)>1,"Duplicate","Unique"))

Blank IDs receive no label. Extend the range if records continue below row 100, and keep the count range consistent across all helper rows. If your spreadsheet uses a locale that requires semicolons as formula separators, replace the commas with semicolons.

Mark later occurrences only

Use an expanding range when the first occurrence should remain unmarked:

=IF(A2="","",IF(COUNTIF($A$2:A2,A2)>1,"Repeat","First"))

Copy the formula down from B2. The first instance of an ID is labeled First; each later instance is labeled Repeat. Sorting the sheet can change which occurrence comes first, so preserve a date or record ID if order matters.

Define the duplicate key

A duplicate depends on the columns you select. Two orders can share a customer ID without being duplicate orders, while a repeated order ID may require investigation. Choose a key that represents the entity or event you want to check.

To find rows with the same customer ID in column A and order date in column B, place this formula in C2 and fill down:

=IF(OR(A2="",B2=""),"",COUNTIFS($A$2:$A$100,A2,$B$2:$B$100,B2))

COUNTIFS counts rows where both criteria match. This example excludes rows missing either key field; change that rule only if incomplete records should form groups. Add another range and criterion for each additional key column, keeping all ranges the same size.

A matching key does not prove that entire rows are identical. Compare other fields, such as amount or status, before deciding which record is correct. Conversely, checking every column can miss duplicate transactions whose notes differ.

Normalize the selected values

Extra spaces and inconsistent capitalization can obscure matches. If IDs are text and those differences should not matter, put a normalized key in B2 and fill it down:

=IF(A2="","",LOWER(TRIM(A2)))

Count duplicates against column B rather than the original IDs. TRIM removes leading and trailing spaces and reduces repeated regular spaces; LOWER standardizes case. This does not fix every invisible character, spelling variation, or inconsistent format. Inspect unusual values before treating normalized matches as equivalent.

Keep original values beside the normalized keys so reviewers can see what changed. Do not normalize case or spacing when those differences carry meaning, and preserve identifiers as text when leading zeros are significant.

Group and count matches

For a compact summary of nonblank values in A2:A100, enter this formula in an empty area or on a report sheet:

=QUERY(A2:A100,"select A, count(A) where A is not null group by A having count(A) > 1 label A 'Value', count(A) 'Count'",0)

The result lists each repeated value once with its group count. It does not include source row numbers or other columns; retain a row-level report when you need to trace individual records. Check that the output area has enough empty cells for the results to expand.

Compare sheets without changing source records

To check whether an ID on Sheet1 also appears on Sheet2, enter this in a helper column on Sheet1 and fill down:

=IF(A2="","",IF(COUNTIF(Sheet2!$A$2:$A$100,A2)>0,"Found on Sheet2","Not found"))

This compares values across sheets; it does not count repetitions within Sheet1 or show which row on Sheet2 matched. Use corresponding normalized keys on both sheets if your matching rules require them. Check the full relevant range on each sheet, including rows added after the formula was created.

For a combined duplicate report, place matching columns from both sheets in one report range and include a source-sheet label and original row number for each record. Then count or group the combined keys. Keep the column order and data types consistent so that records from both sheets are compared under the same rules.

Inspect the duplicate report

Review group counts and individual records before making changes. A count of three means three matching rows in the selected range, not necessarily three records to delete. Confirm whether the first row is a valid original, whether later rows contain updates, and whether the key is specific enough.

  1. Filter the helper count column for values greater than 1.
  2. Compare the key and surrounding fields for each matching group.
  3. Record the sheet name and original row number alongside each finding.
  4. Decide separately whether to correct, retain, or remove any record.

The embedded duplicate checker can also check selected columns in pasted sheet data and return grouped counts and row indexes. Its check is read-only; review what the pasted data represents and map reported indexes back to the source before acting.

Export evidence

For a manual report, include source sheet, original row number, key fields, count, and any review notes in a separate sheet. Enter row numbers before sorting or filtering, so the exported evidence still points to the original records. If the source may change, preserve a dated copy or record the version reviewed.

Download the report sheet through File → Download in a suitable format. Check the downloaded file for headers, complete rows, and readable identifiers; some formats can interpret long numbers or leading zeros differently. The embedded checker also supports downloading its duplicate evidence. Neither a formula report nor a read-only check deletes source records, so any cleanup remains a separate, reviewed action.

FAQ

Does this page delete duplicate function google sheets?

No, it returns a read-only duplicate report.

Run read-only duplicate check to inspect duplicate detection, grouping, and report export and export a controlled report without destructive cleanup.

Run read-only duplicate check to inspect duplicate detection, grouping, and report export and export a controlled report without destructive cleanup.

Run read-only duplicate check

Run read-only duplicate check