Driver FixRecommendedSound, Wi-Fi or graphics acting up? Check drivers firstFind missing or outdated drivers fast.Check DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsClean PCRecommendedOne scan can reveal what keeps slowing WindowsLook for cleanup and repair opportunities.Run Scan×
Skip to content
World desk3 min

How to Find and Highlight Differences Between Two Excel Columns

Use Conditional Formatting to flag mismatches between corresponding rows, or COUNTIF to find values missing from a differently ordered Excel list.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

For rows that represent matching records, use a formula-based Conditional Formatting rule: =A2<>B2. For lists that may be in a different order, check whether each value appears anywhere in the other column with COUNTIF. The right method depends on whether you are comparing row by row or looking for missing list entries.

Compare corresponding rows and highlight mismatches

Use this method when the value in each row of column A is meant to match the value in the same row of column B. For example, it works when two columns contain fields for the same records in the same order.

As an Amazon Associate I earn from qualifying purchases.

  1. Select the cells you want formatted. Select A2:B100 to highlight differences on either side, or A2:A100 to highlight only column A.
  2. Choose Home > Conditional Formatting > New Rule, then choose the option for using a formula to determine which cells to format. Excel’s menus can vary by platform or version.
  3. Enter =A2<>B2, then choose a fill or font format and confirm the rule.
  4. Check a few known matches and mismatches. Confirm the rule applies to the intended range and that the formula’s row number matches the first row in that range.

Conditional Formatting applies the chosen format when the formula evaluates to TRUE. When the rule is applied to both columns, Excel adjusts the relative references for each cell; the comparison still checks the two cells in the same row. If you select only column A, the rule compares each A cell with its B counterpart.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Make text comparisons case-sensitive

The standard comparison treats capitalization as equivalent for text. If ABC and abc must count as different, use =NOT(EXACT(A2,B2)) as the Conditional Formatting formula, keeping the references aligned with the first row of the selected range. Microsoft Support says EXACT is case-sensitive but ignores formatting differences.

Find values missing from a differently ordered list

If the columns contain the same kind of list but their rows are not paired, comparing A2 with B2 can flag ordinary ordering differences rather than missing values. Instead, check whether each entry in one column appears anywhere in the other.

  1. Select the data cells in column A that you want to check.
  2. Create a formula-based Conditional Formatting rule and enter =COUNTIF($B:$B,A2)=0, replacing the row number with the first selected data row if needed.
  3. Choose a format and apply the rule. It highlights A values for which no match is found in column B.
  4. To find values in B that do not appear in A, select the B data cells and use =COUNTIF($A:$A,B2)=0, adjusting the row reference to the selection’s first row.

COUNTIF matching is case-insensitive and supports wildcard criteria. Microsoft notes that text strings longer than 255 characters can produce incorrect results; extra spaces, inconsistent quotation marks, and nonprinting characters can also cause unexpected matches. If results look wrong, inspect and clean the source values before relying on the highlights. See Microsoft’s COUNTIF guidance.

Check how blank cells should be treated

Before applying either formula, decide what an empty cell means in your data. In a same-row comparison, two empty cells compare as equal, while an empty cell paired with a nonempty value is a mismatch. In a membership check, a blank being checked can match a blank elsewhere in the searched column, so the zero-count rule will not flag it as missing if that column contains a blank. If blanks should be excluded, select only populated data rows or handle blanks separately.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Compare entire workbook versions

For two workbook versions, rather than just two columns, Microsoft’s Spreadsheet Compare can inspect differences in values, formulas, and formatting cell by cell. Microsoft lists it as available only with Microsoft 365 Apps for enterprise; check your installed edition before looking for the utility. See Microsoft’s Spreadsheet Compare guidance.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Choose the formula that fits the comparison

Question Conditional Formatting formula What it identifies
Do the two cells in each row differ? =A2<>B2 Same-row mismatches; capitalization is not distinguished.
Do the two text cells differ, including capitalization? =NOT(EXACT(A2,B2)) Same-row differences that are case-sensitive.
Does each A value appear somewhere in B? =COUNTIF($B:$B,A2)=0 A values absent from B, without regard to capitalization.
Does each B value appear somewhere in A? =COUNTIF($A:$A,B2)=0 B values absent from A, without regard to capitalization.

In every formula, adapt the row reference to the first data row in the selected range. Use a row-by-row formula only when the rows correspond; use COUNTIF when list order does not matter.

Best Value
Sale
The Microsoft Office 365 Bible: The Most Updated and Complete Guide to Excel, Word, PowerPoint, Outlook, OneNote, OneDrive, Teams, Access, and Publisher from Beginners to Advanced
  • The Microsoft Office 365 Bible: The Most Updated and Complete Guide to Excel, Word, PowerPoint, Outlook, OneNote, OneDrive, Teams, Access, and Publisher from Beginners to Advanced
  • ABIS BOOK

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Windows Errors? Fix Them Before They SpreadFree repair scan
Crashes, No Sound, or Screen Glitches?Free driver scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.