
Compares two text strings and returns TRUE only when they match exactly, including letter case.
The Excel EXACT function compares two text values and returns TRUE only when they match exactly. That includes uppercase and lowercase letters, spaces, and punctuation.
EXACT is different from the normal = comparison. In Excel, ="Apple"="apple" returns TRUE because the standard comparison ignores case. EXACT does not ignore case.
Returns TRUE only when both text values match completely.
Returns a logical result that can be used directly or inside another formula.
=EXACT(text1, text2)
text1 and text2 are the two values you want to compare. Both arguments are required.
EXACT fills a specific gap: it gives you a case-sensitive text comparison. Most other common comparison tools in Excel are case-insensitive by default.
| Method | Case-Sensitive? | Use When |
|---|---|---|
EXACT |
Yes | Letter case must match exactly |
= |
No | Case does not matter |
FIND |
Yes | You need a case-sensitive position search rather than a full comparison |
EXACT is useful when case carries meaning. That can happen in revision codes, imported identifiers, passwords, or validation checks where "REV-A" should not be treated as the same as "rev-a".
If two values look the same but EXACT still returns FALSE, the problem may be an extra space or another hidden character. In that case, trimming or cleaning the text before comparison can help.
This example shows the main reason EXACT exists. The normal comparison ignores case, while EXACT does not.
="Excel"="excel" // TRUE
=EXACT("Excel","excel") // FALSE
In cell F1, use EXACT to compare "Excel" with "excel". Expected result: FALSE.
EXACT works the same way with cell references. If even one letter differs in case, the result is FALSE.
=EXACT(A1,B1)
// "Pass123" vs "pass123" -> FALSE
In cell F2, use EXACT to compare A1 ("Pass123") with B1 ("pass123"). Expected result: FALSE.
Wrapping EXACT inside IF can make the result easier to scan in a worksheet. This is useful in review or validation columns.
=IF(EXACT(C1,D1), "Match", "Different")
In cell F3, use EXACT inside an IF to show "Match" or "Different" when comparing C1 with D1.
EXACT can compare a cell against a required text value when the case must match exactly.
=EXACT(E1, "REV-A")
// TRUE only if E1 contains exactly "REV-A"
In cell F4, use EXACT to check if E1 equals exactly "REV-A".
EXACT is often enough for one-to-one checks, but case-sensitive counting needs a different pattern such as SUMPRODUCT with EXACT.
EXACT compares two text values with case sensitivity.=EXACT(text1, text2).= comparison does not: it respects letter case.Tell your friends about this post