Function Problems

Use COUNTIF Wildcards to Find Text in Excel

Muhammad TalhaMuhammad Talha Nov 22, 2026 869 views

Question details

The user needs the correct COUNTIF syntax to check whether a cell contains the character 1.

Use COUNTIF Wildcards to Find Text in Excel
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.
Before you start

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.

Solution 1Recommended

Count cells containing 1 with COUNTIF

Use this formula when you want to count text cells containing the character 1.

1
Select a result cell

Click an empty cell where you want the count to appear.

2
Enter the formula

Type =COUNTIF(A3,"*1*") and press Enter. The quotation marks enclose the entire criterion, and the asterisks match any text before or after 1.

3
Adjust the range

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.

Count cells containing 1 with COUNTIF
Numeric values: Wildcard criteria do not match numbers stored as numeric values. To include them, enter =A3&"" in a helper cell, fill it down for the range, and apply COUNTIF to the helper cells.
Search spreadsheet text

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. 1. Open your spreadsheet: Open WPS Spreadsheets and select File > Open to choose your workbook.
  2. 2. Choose a result cell: Click an empty cell where you want to display the count.
  3. 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. 4. Save your changes: Select File > Save or Save As to save the workbook.
Count matching text cells with COUNTIF wildcardsOpen and edit Microsoft Excel XLSX and XLS filesUse familiar spreadsheet formulas and cell references
microsoft office alternative - wps office

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.