Skip to main content

How to compare two worksheets in a workbook or two workbooks for differences in Excel?

Author Siluvia Last modified

As the below screenshot shown, have you ever tried to compare two worksheets for differences in Excel? This article is going to show you methods of comparing two spreadsheets for differences in the same Excel file or different Excel files in Excel. Please browse for more details.

compare two worksheets  for differences

Compare two worksheets for differences in an Excel file with formula
Highlight differences between two worksheets with Conditional Formatting
Easily compare two sheets for differences in an Excel file or two Excel files


Compare two worksheets for differences in the same workbook with formula

Supposing you have two spreadsheets in an Excel file as below screenshot shown. For comparing the sales columns for differences between these two sheets and listing the compared result in a new sheet, please do as follows.

sample data in two sheets

1. Create a new sheet to placing the compared result, select a blank cell (here I select cell B5) in the new sheet, copy and paste the below formula into it and press the Enter key. Keep selecting cell C2, drag the fill handle to the right cell and then drag down to list all compared results.

Formula:

=IF(Sheet1!B5 <> Sheet2!B5, "Sheet1:"&Sheet1!B5&" VS. Sheet2:"&Sheet2!B5, "Match")

Notes:

1). In the formula, Sheet1 and Sheet2 are the worksheets you will compare with.

2). B5 is the first compared cell of the two tables. Please change them as you need.

use a formula to compare two worksheets for differences

You can see the result as below screenshot shown.

get the results


Easily compare two sheets for differences in an Excel file or two Excel files:

The Select Same & Different Cells utility of Kutools for Excel can help you to easily compare two worksheets for differences in a workbook or different workbooks. All differences will be selected automatically after comparing. It is optional to highlight the different cells by adding background color or font color as the below demo shown. Download and try it now! (30-day free trail)


Highlight differences between two worksheets with Conditional Formatting

Besides, you can highlight all cells that have different values in two worksheets by using the Excel build-in function - Conditional Formatting.

1. Select the whole table in the worksheet that you will highlight different value cells in it (in this case, I select table 1 in Sheet1), and then enable the Conditional Formatting function by clicking Conditional Formatting > New Rule under the Home tab. See screenshot:

click Conditional Formatting > New Rule under the Home tab

2. In the New Formatting Rule dialog box, you need to:

  • 2.1) Select Use a formula to determine which cells to format option in the Select a Rule Type dialog;
  • 2.2) Enter the below formula into the Format values where this formula is true box;
  • 2.3) Click the Format button to specify a highlight color for the differences;
  • 2.4) Click the OK button. See screenshot:

Formula:

=B4<>Sheet2!B4

Note:

In the formula, B4 is the first cell of the compared ranges. Sheet2 is the worksheet you will compare with.

specify the options in the dialog box

Now all differences in table 1 compared with table 2 in Sheet2 are highlighted immediately as below screenshot shown.

the differences are highlighted


Easily compare two sheets for differences in an Excel file or two Excel files

This section will introduce the Select Same & Different Cells utility of Kutools for Excel. With this utility, you can easily compare two worksheets for differences in an Excel file or two Excel files as you need.

Kutools for Excel offers over 300 advanced features to streamline complex tasks, boosting creativity and efficiency. Itegarate with AI capabilities, Kutools automates tasks with precision, making data management effortless. Detailed information of Kutools for Excel...         Free trial...

1. Select the whole table in the worksheet that you will highlight different value cells in it (in this case, I select table 1 in Sheet1), and then click Kutools > Select > Select Same & Different Cells.

click Select Same & Different Cells feature of kutools

2. In the Select Same & Different Cells dialog box, you can see the selected table range is placing in Find values in box, please go ahead to:

  • 2.1) Select the range you will compared with in another worksheet of current workbook or different workbook in the According to box;
  • 2.2) Select Each row in the Based on section;
  • 2.3) Select the Different Values option;
  • 2.4) Click the OK button. See screenshot:

specify options in the dialog box

Notes:

1. Check the My data has headers if the selected range contains header;

2. Check the Fill backcolor or the Fill font color option in the Processing of results section to outstand the differences with certain background color or font color as you need.

Now all differences in Table 1 of Sheet1 are selecting or highlighting immediately after comparing with Table 2 in Sheet2. See screenshot:

the differences are highlighted

  If you want to have a free trial (30-day) of this utility, please click to download it, and then go to apply the operation according above steps.


Best Office Productivity Tools

🤖 Kutools AI Aide: Revolutionize data analysis based on: Intelligent Execution   |  Generate Code  |  Create Custom Formulas  |  Analyze Data and Generate Charts  |  Invoke Kutools Functions
Popular Features: Find, Highlight or Identify Duplicates   |  Delete Blank Rows   |  Combine Columns or Cells without Losing Data   |   Round without Formula ...
Super Lookup: Multiple Criteria VLookup    Multiple Value VLookup  |   VLookup Across Multiple Sheets   |   Fuzzy Lookup ....
Advanced Drop-down List: Quickly Create Drop Down List   |  Dependent Drop Down List   |  Multi-select Drop Down List ....
Column Manager: Add a Specific Number of Columns  |  Move Columns  |  Toggle Visibility Status of Hidden Columns  |  Compare Ranges & Columns ...
Featured Features: Grid Focus   |  Design View   |   Big Formula Bar    Workbook & Sheet Manager   |  Resource Library (Auto Text)   |  Date Picker   |  Combine Worksheets   |  Encrypt/Decrypt Cells    Send Emails by List   |  Super Filter   |   Special Filter (filter bold/italic/strikethrough...) ...
Top 15 Toolsets12 Text Tools (Add Text, Remove Characters, ...)   |   50+ Chart Types (Gantt Chart, ...)   |   40+ Practical Formulas (Calculate age based on birthday, ...)   |   19 Insertion Tools (Insert QR Code, Insert Picture from Path, ...)   |   12 Conversion Tools (Numbers to Words, Currency Conversion, ...)   |   7 Merge & Split Tools (Advanced Combine Rows, Split Cells, ...)   |   ... and more
Use Kutools in your preferred language – supports English, Spanish, German, French, Chinese, and 40+ others!

Supercharge Your Excel Skills with Kutools for Excel, and Experience Efficiency Like Never Before. Kutools for Excel Offers Over 300 Advanced Features to Boost Productivity and Save Time.  Click Here to Get The Feature You Need The Most...


Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier

  • Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
  • Open and create multiple documents in new tabs of the same window, rather than in new windows.
  • Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!