Use COUNTIF Wildcards to Find Text in Excel
Question details
The user needs the correct COUNTIF syntax to check whether a cell contains the character 1.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- Search a cell or range for text containing the character 1.
- Observed behavior
- The desired result is a count of matching cells or a Yes or No indication for a single cell.
Identify the cell or range you want to search and check whether its values are stored as text or numbers. COUNTIF wildcard criteria match text, so numeric values may need to be converted to text first.
Count cells containing 1 with COUNTIF
Use this formula when you want to count text cells containing the character 1.
Click an empty cell where you want the count to appear.
Type =COUNTIF(A3,"*1*") and press Enter. The quotation marks enclose the entire criterion, and the asterisks match any text before or after 1.
To search multiple cells, replace A3 with your range, for example =COUNTIF(A3:A10,"*1*"). For a single cell, A3 is sufficient; A3:A3 is unnecessary.

Return Yes or No with FIND
Use FIND when you want a text result instead of a count for one cell.
Find text with COUNTIF in WPS Spreadsheets
Use the same COUNTIF wildcard criterion in WPS Spreadsheets to count text cells containing the character 1.
- 1. Open your spreadsheet: Open WPS Spreadsheets and select File > Open to choose your workbook.
- 2. Choose a result cell: Click an empty cell where you want to display the count.
- 3. Enter COUNTIF: Type =COUNTIF(A3,"*1*") and press Enter. Replace A3 with a range such as A3:A10 to count matching text cells across that range.
- 4. Save your changes: Select File > Save or Save As to save the workbook.

Frequently Asked Questions
Why must the wildcards be inside quotation marks?
COUNTIF treats "*1*" as a text criterion. The asterisks match any sequence of characters before or after 1.
How do I count matches across several cells?
Replace the single-cell reference with a range, such as =COUNTIF(A3:A10,"*1*"). The result counts matching cells, not individual occurrences of 1.
Why doesn't COUNTIF find 1 in a numeric cell?
Wildcard criteria match text rather than numeric values. Convert the value in a helper cell with =A3&"", then apply COUNTIF to the helper cell or range.
How can I display Yes or No instead of a count?
Enter =IF(ISNUMBER(FIND("1",A3&"")),"Yes","No") in an empty cell. Replace A3 with the cell you want to search.




