CSV comparison by key
Compare two small CSV exports by a unique key and inspect added, removed and changed cells.
- 1Add input
- 2Adjust settings
- 3Get your result
Tool input and files are processed in this browser without being uploaded.
Before you start
Paste or import old and new UTF-8 CSV tables, choose a shared unique key, then review added, removed and changed records by column. Record order does not affect the comparison.
How to use this tool
- Paste or import the old and new UTF-8 CSV, each with a header row; confirm row and column counts.
- Choose a shared key column and correct blank or duplicate keys before comparing.
- Review added, removed and changed counts, inspect changed cells and schema differences, then download the JSON or CSV reports.
Supported inputs and limits
Each side is limited to 1 MiB of UTF-8 CSV text, with at most 200,000 parsed cells. Both tables need headers and a shared key column whose values are nonblank and unique within each side.
Key and cell values are compared as exact strings: leading zeroes, spaces and letter case are significant. Only shared non-key columns are compared cell by cell; added and removed column names are listed separately.
The page previews up to 100 added/removed records, 200 changed cells and 12 columns; complete differences can be downloaded as JSON and, when applicable, separate CSV files. CSV exports prefix formula-like values for safer spreadsheet opening; JSON preserves the source strings. No file is uploaded or automatically merged into a master table.
JSON exports complete added/removed records and every changed shared cell; changed records are not exported as paired full old/new rows.
Worked example
Example input
id,name 001,Ada 002,Bo New CSV: id,name 001,Ada Lovelace 003,Cy
Example options
{"key": "id"}Example output
{
"added": [
{
"id": "003",
"name": "Cy"
}
],
"removed": [
{
"id": "002",
"name": "Bo"
}
],
"changed": [
{
"key": "001",
"cells": [
{
"column": "name",
"before": "Ada",
"after": "Ada Lovelace"
}
]
}
],
"columnsAdded": [],
"columnsRemoved": []
}When something does not work
Use two UTF-8 CSV tables under 1 MiB each with consistent row widths and unique, nonblank keys. Choose a column name present on both sides; if your export is larger, reduce the data before comparing.
Frequently asked questions
Does a changed row order count as a difference?
No. Rows match by the exact value in the selected unique key column. Leading zeroes remain significant; other shared columns are compared as strings.
Can I download the difference as CSV?
Yes. When present, added records, removed records and changed cells each have a separate CSV download. The complete JSON report also includes added/removed column names. CSV export guards formula-like values with an apostrophe.
Can it update my master CSV or compare very large exports?
No. It reports differences without rewriting either source. Each side is limited to 1 MiB and 200,000 parsed cells; larger exports need a different workflow.