What does comparing two spreadsheets actually mean?
There are three different questions hiding behind "compare these two files", and each one needs a different method. Decide which question you are asking before you pick a tool.
Cell by cell: is the value in A1 of the old file the same as the value in A1 of the new file, and so on for every cell? This works when both files have the same layout and nobody inserted or deleted rows. A budget updated in place, a price list with the same items in the same order, or two exports of the same report fit here.
By key column: each row has an ID, an email, a SKU or an invoice number, and you want to know whether the row with ID 1042 changed, regardless of where it sits. This is the right question when rows were sorted, filtered, added or removed between the two versions. Customer lists, inventories and order exports almost always need this mode. Comparing by row order, where you only care whether the same rows are present, is a cell by cell comparison after sorting both files the same way.
Compare two Excel files online with a position or key mode
The fastest way to get a complete list of differences is an online compare tool. Compare Excel takes two versions of a spreadsheet and finds every changed, added or removed cell. It has two modes that match the two questions above: position mode compares the same cell address in both files, and key mode matches rows by a column you choose, such as an ID or an email, then compares the matched rows.
It is free, needs no sign-up, accepts files up to 300 MB and works in the browser on a phone or a computer. Files are processed in memory and deleted after 30 minutes.
- Open Compare Excel and add the old version and the new version.
- Pick position mode if the rows are in the same order in both files, or key mode and choose the ID column if rows may have moved.
- Run the comparison and read the result: changed cells with the old and new value, rows that exist only in the new file, and rows that disappeared.
- Download the report and keep it with the files if you need to show what changed.
Use View Side by Side in Excel
For a small sheet you can scan by eye, Excel's View Side by Side is enough and needs nothing extra. Open both workbooks, go to the View tab and click View Side by Side. Excel stacks the two windows and turns on Synchronous Scrolling, so scrolling one sheet scrolls the other to the same row. Click Arrange All and choose Vertical if you prefer the windows next to each other.
To compare two sheets inside the same workbook, click View, New Window first. Excel opens a second window on the same file; switch it to the other sheet, then use View Side by Side as before. This method shows you the sheets, not the differences; it is fine for a few dozen rows and useless for a thousand.
Highlight differences with conditional formatting
Conditional formatting colors every cell whose value differs from the matching cell in the other sheet. It works when both sheets have the same layout, so it answers the cell by cell question. Put both sheets in the same workbook first: right-click the sheet tab in the second file, choose Move or Copy, and copy it into the first workbook as Sheet2.
Then select the whole used range on the first sheet starting at A1, open Home, Conditional Formatting, New Rule, and choose Use a formula to determine which cells to format. Enter =A1<>Sheet2!A1, pick a fill color under Format, and click OK. Excel adjusts the reference for every cell in the selection, so B7 is compared with Sheet2!B7 and so on.
Use relative references without dollar signs or the rule compares every cell with the same one.
Match rows by ID with XLOOKUP or VLOOKUP
When rows moved, a lookup formula pulls the value from the other sheet by ID so you can compare the right pairs. With the two sheets in one workbook and the ID in column A, add a helper column on Sheet1 with =XLOOKUP(A2,Sheet2!A:A,Sheet2!C:C,"missing"). It returns the column C value for the same ID on Sheet2, or the word missing if the ID is not there. In the next column, =IF(C2=D2,"","changed") flags the rows that differ. Fill both down.
In older versions without XLOOKUP, use =VLOOKUP(A2,Sheet2!A:C,3,FALSE) and wrap it in IFERROR to catch missing IDs. The FALSE argument matters: without it Excel returns the nearest match and your comparison lies.
To find rows that were added in the new file, use =COUNTIF(Sheet1!A:A,A2) on Sheet2: a zero means the ID exists only in the new version. One lookup column per field gets tedious past three or four columns, which is where a key mode comparison tool saves the afternoon.
Spreadsheet Compare in Microsoft 365 for Windows
Some business editions of Office on Windows include a separate program called Spreadsheet Compare. Type its name in the Start menu; if nothing appears, your edition does not include it and there is no way to add it on its own. It is not available on Mac or in the web version of Excel.
Open it, click Compare Files, pick the earlier file on the left and the later one on the right, and click OK. It lists every difference in a grid and colors the cells by type: entered values, calculated values, formulas, formatting and structural changes such as inserted rows. You can untick categories you do not care about, and the Export Results button writes the list to a new workbook. It compares by position, so if rows were resorted it reports almost everything as changed.
Compare two sheets in Google Sheets
Google Sheets has no compare command, but the same formula tricks work. Import both files into one spreadsheet with File, Import, choosing Insert new sheet(s) for the second file. If your files are XLSX, XLSX to Google Sheets walks through the import and offers a CSV fallback when a workbook refuses to open.
For a cell by cell view, select the range on the first sheet, open Format, Conditional formatting, choose Custom formula is, and enter =A1<>INDIRECT("Sheet2!"&ADDRESS(ROW(),COLUMN())). The INDIRECT wrapper is needed because Google Sheets does not accept a direct cross-sheet reference in a conditional format. For key matching, XLOOKUP and VLOOKUP work exactly as in Excel.
If both versions are the same Google Sheets file edited over time, skip all of this and open File, Version history, See version history, which shows who changed which cells and when.
How to read the result
Every comparison produces three kinds of findings. Changed cells are present in both versions with a different value; look at the old and new value together, because a change from 1,200 to 1,250 and a change from 1,200 to blank mean very different things. Added rows exist only in the newer file. Removed rows exist only in the older file. In a key comparison, a row that shows as both removed and added usually had its ID edited.
Decide early whether you care about formulas or values. A formula that now returns a different number because an input changed is a value difference, not an edit. A cell that went from =SUM(B2:B9) to a typed 4,580 is an edit that will not update again, and it is the kind of change that quietly breaks a budget. Formatting changes such as colors and column widths rarely matter unless a color carries meaning, such as red for overdue.
Common traps that make identical data look different
Most false differences come from the same handful of causes. Trailing spaces: "Smith " and "Smith" are different strings to Excel. Numbers stored as text: a 42 typed into a cell formatted as Text does not equal the number 42, and shows a small green triangle in the corner. Dates: one file holds a real date (a serial number such as 46022) and the other holds the text 01/15/2026, so they never match even though they display the same. Rounding: 0.1+0.2 is stored as 0.30000000000000004 and will not equal a typed 0.3 unless you wrap both in ROUND.
The cure is to normalize both files before comparing. Run them through Clean up spreadsheet, which trims spaces and fixes numbers stored as text, or do it by hand with TRIM, VALUE and DATEVALUE in helper columns. Also clear filters and unhide rows and sheets in both files: a filter hides rows from your eyes, not from a comparison.
Frequently asked questions
How do I compare two Excel files for differences?
Upload both versions to a compare tool such as DocGopher's Compare Excel, which lists every changed, added or removed cell, or open both in Excel and use View Side by Side for a visual check. For a formula approach, copy both sheets into one workbook and add a conditional formatting rule with =A1<>Sheet2!A1.
How do I compare two Excel sheets when the rows are in a different order?
Match rows by a key column such as an ID instead of by position. In Excel, use =XLOOKUP(A2,Sheet2!A:A,Sheet2!C:C,"missing") to pull the other sheet's value for the same ID, then compare the two columns. Compare tools with a key mode do this for every column at once.
How do I compare two columns in Excel for matches?
In a third column, enter =IF(A2=B2,"same","different") and fill it down to compare row by row. To check whether each value in column A appears anywhere in column B, use =COUNTIF(B:B,A2), where 0 means no match.
Does Excel have a built-in compare tool?
Excel itself has View Side by Side for a visual comparison, but no difference report. Some business editions of Office on Windows include a separate program called Spreadsheet Compare that lists changes by type. It is not available on Mac or in Excel for the web.
Why does Excel say two identical cells are different?
One cell usually has a trailing space, is a number stored as text, or holds a date as text while the other holds a real date. Trim spaces, convert text to numbers with VALUE, and convert text dates with DATEVALUE before comparing.