Table of Contents
In order to compare three columns in Excel, you can use the IF and AND functions to create a formula that will check for similarities or differences between the data in the three columns. For example, if you have three columns A, B, and C, you can use a formula like =IF(AND(A1=B1,B1=C1), “Match”, “No Match”) to compare the values in each row of the three columns and return “Match” if all three values are identical or “No Match” if there is a difference. This allows for a quick and efficient comparison of multiple data sets in Excel.
Compare Three Columns in Excel (With Example)
You can use the following basic formula to compare three columns in Excel:
=IF(AND(B2=C2,C2=D2),"Equal","Not Equal")
This particular formula compares the values in cells B2, C2, and D2.
If all of the values are equal, the formula returns Equal. Otherwise, it returns Not Equal.
The following example shows how to use this formula in practice.
Example: Compare Three Columns in Excel
Suppose we have the following dataset that shows the highest scorer on various basketball teams during three different games:

We can type the following formula into cell E2 to test if the three values in the first row are all equal:
=IF(AND(B2=C2,C2=D2),"Equal","Not Equal")
The following screenshot shows how to use this formula in practice:

The formula returns Not Equal since the three names in the first row don’t all match.
We can then drag this formula in cell E2 down to the remaining cells in column E to test for matches in each row:

Notice that the formula only returns Equal for the rows where the cell values are equal across each of the three columns.
You can also apply conditional formatting to the rows where all three cell values are equal by highlighting the cell range E2:E11, then clicking on the Conditional Formatting button on the Home tab, then clicking Highlight Cell Rules, then clicking Equal To:

In the new window that appears, type Equal into the box and choose a fill color, then click OK:

The rows that have matching values across all three columns will now be filled with green:

The following tutorials explain how to perform other common tasks in Excel:
Cite this article
stats writer (2024). How can I compare three columns in Excel using an example?. PSYCHOLOGICAL SCALES. Retrieved from https://scales.arabpsychology.com/stats/how-can-i-compare-three-columns-in-excel-using-an-example/
stats writer. "How can I compare three columns in Excel using an example?." PSYCHOLOGICAL SCALES, 27 Jun. 2024, https://scales.arabpsychology.com/stats/how-can-i-compare-three-columns-in-excel-using-an-example/.
stats writer. "How can I compare three columns in Excel using an example?." PSYCHOLOGICAL SCALES, 2024. https://scales.arabpsychology.com/stats/how-can-i-compare-three-columns-in-excel-using-an-example/.
stats writer (2024) 'How can I compare three columns in Excel using an example?', PSYCHOLOGICAL SCALES. Available at: https://scales.arabpsychology.com/stats/how-can-i-compare-three-columns-in-excel-using-an-example/.
[1] stats writer, "How can I compare three columns in Excel using an example?," PSYCHOLOGICAL SCALES, vol. X, no. Y, ص Z-Z, June, 2024.
stats writer. How can I compare three columns in Excel using an example?. PSYCHOLOGICAL SCALES. 2024;vol(issue):pages.
