Function Problems

Use IF to Check Multiple Letter Values in Excel

Muhammad TalhaMuhammad Talha Dec 2, 2026 868 views

Question details

The user wants to test whether a cell matches one of several letters or begins with one of those letters without using many nested IF functions.

Use IF to Check Multiple Letter Values in Excel
Product
Microsoft Excel
Device & OS
not provided
Scenario
Evaluate a cell against a list of possible letters and return a result based on the match.
Observed behavior
The formula should return one result when an exact letter or specified starting letter is found and another result otherwise.
Before you start

Identify the cell to check and the letters you want to match. Decide whether the cell must contain only the letter or can contain additional characters after it.

Solution 1Recommended

Check for Exact Letter Matches with IF and OR

Use this formula when the cell must contain exactly one of the specified letters.

1
Enter the formula

Select an empty cell and enter =IF(OR(J2="A",J2="B",J2="C",J2="D"),"TRUE","FALSE").

2
Adjust the references

Replace J2 with the cell you want to check, and edit the letters or add more comparisons inside OR.

3
Apply the formula

Press Enter, then drag the fill handle down to check other rows.

Check for Exact Letter Matches with IF and OR
Text versus Boolean results: The quoted results "TRUE" and "FALSE" are text. Remove the quotation marks around them if you need Boolean TRUE and FALSE values.
Work with formulas in WPS Spreadsheets

Check Multiple Letter Values in WPS Spreadsheets

Use IF and OR in WPS Spreadsheets to check a cell against multiple exact letter values without nesting IF functions.

  1. 1. Open your workbook: Open WPS Spreadsheets and select Open to load your Excel workbook.
  2. 2. Enter the formula: Select an empty cell and enter =IF(OR(J2="A",J2="B",J2="C",J2="D"),"TRUE","FALSE").
  3. 3. Adapt and apply: Change J2 and the letters to match your data, press Enter, and drag the fill handle down for other rows.
  4. 4. Save the workbook: Select File > Save As and choose an Excel format such as XLSX.
Check multiple letter values in one formulaOpen and edit Microsoft Excel XLSX and XLS filesUse a familiar spreadsheet interfaceApply formulas to additional rows with the fill handle
microsoft office alternative - wps office

Frequently Asked Questions

How do I add another letter to the exact-match formula?

Add another comparison inside OR. For example, add J2="E" after the existing comparisons, separated by a comma.

Can IF use a wildcard directly to test a cell?

A comparison such as J2="A*" treats the asterisk as a literal character. Use COUNTIF(J2,"A*") to match text beginning with A.

Will the exact-match formula accept a lowercase letter?

Yes. Excel's standard text comparisons are not case-sensitive, so J2="A" also matches lowercase a.

How can I return labels instead of TRUE and FALSE?

Replace the quoted results in IF with your labels, such as =IF(OR(J2="A",J2="B"),"Match","No match").