How to count the number of times a character / word appears in a cell?

This article, I will talk about how to count the number of times a specific character or a word appears in a cell in a worksheet. For example, A2 contains the text “Kutools for outlook and Kutools for word”, and now, I want to know the number of the letter “o” in this cell. In Excel, we can apply formulas to deal with this job.

Count the number of times a character or word appears with formulas

Count the number of times a character or word appears with an easy feature


Count the number of times a character or word appears with formulas

To count the number of occurrences of a wordor a character in a cell, you can use the formula which combines SUBSTITUTE and LEN functions. Please do as follows:

Enter the below formula into a blank cell, and then press Enter key to get the number of times the character appears, see screenshot:

=(LEN(A2)-LEN(SUBSTITUTE(A2, "remove","")))/LEN("remove")

Notes:

1. In the above formula, A2 is the text cell that you want to count, the word “remove” is the specified character that you want to count its occurrences

2. With above formula, you can also count the number of a specific character appears in a cell, you just need to change the word "remove" to the character as you want, see the following screenshot:

=(LEN(A2)-LEN(SUBSTITUTE(A2, "o","")))/LEN("o")

3. This formula is case sensitive.

4. To count number of the specific word or charater appears without case sensitive, please apply the following formula:

=(LEN(A2)-LEN(SUBSTITUTE(UPPER(A2),UPPER("remove"),"")))/LEN("remove")


Count the number of times a character or word appears with an easy feature

If you have Kutools for Excel, you can use its Count the number of a word of Commonly-Used Formulas to count the times a certain character or a word occurs.

Note:To apply the Count the number of a word features, firstly, you should download the Kutools for Excel, and then apply the features quickly and easily.

After installing Kutools for Excel, please do as this:

1. Click a cell where you want to output the result.

2. Then click Kutools > Formula Helper > StatisticalCount the number of a word, see screenshot:

3. And in the popped out Formulas Helper dialog box, click doc-count-character-appears-5 button to select the cell that you want to cout the specifc word or character from the Text box, and then enter the word or character that you want to count in the Word text box, see screenshot:

4. Then click OK to close the dialog, and you will get the correct result as you want.

Note: This feature is case sensitive.

Click to Download Kutools for Excel for free trial Now


More relative articles:

  • Count The Number Of Spaces Of Text String
  • Have you ever tried to count the number of spaces of text string in a cell? Of course, you can count them one by one manually, but, if there are multiple cells needed to be counted, this way will be tedious and time consuming.
  • Count The Number Of Words In A Cell Or A Range Cells
  • You can easily count the number of words in MS Word, but Excel doesn't have a built-in tool for counting the number of words in a worksheet. However, you can count the number of words in Excel with following methods.
  • Count Cells If One Of Multiple Criteria Met
  • The COUNTIF function will help us count cells containing one criteria, and the COUNTIFS function can help up count cells containing a set of conditions or criteria in Excel. What if counting cells if contain one of multiple criteria? Here I will share the ways to count cells if contain X or Y or Z … etc. in Excel.
  • Count Comma Separated Values In A Single Cell
  • If cell content is separated by comma in a single cell, such as “A1, A2, A3, A4, A5”, and you want to count the total number of comma separated values in this cell, what can you do? In this case, the total comma separated values should be 5.

The Best Office Productivity Tools

Kutools for Excel Solves Most of Your Problems, and Increases Your Productivity by 80%

  • Reuse: Quickly insert complex formulas, charts and anything that you have used before; Encrypt Cells with password; Create Mailing List and send emails...
  • Super Formula Bar (easily edit multiple lines of text and formula); Reading Layout (easily read and edit large numbers of cells); Paste to Filtered Range...
  • Merge Cells/Rows/Columns without losing Data; Split Cells Content; Combine Duplicate Rows/Columns... Prevent Duplicate Cells; Compare Ranges...
  • Select Duplicate or Unique Rows; Select Blank Rows (all cells are empty); Super Find and Fuzzy Find in Many Workbooks; Random Select...
  • Exact Copy Multiple Cells without changing formula reference; Auto Create References to Multiple Sheets; Insert Bullets, Check Boxes and more...
  • Extract Text, Add Text, Remove by Position, Remove Space; Create and Print Paging Subtotals; Convert Between Cells Content and Comments...
  • Super Filter (save and apply filter schemes to other sheets); Advanced Sort by month/week/day, frequency and more; Special Filter by bold, italic...
  • Combine Workbooks and WorkSheets; Merge Tables based on key columns; Split Data into Multiple Sheets; Batch Convert xls, xlsx and PDF...
  • More than 300 powerful features. Supports Office/Excel 2007-2019 and 365. Supports all languages. Easy deploying in your enterprise or organization. Full features 30-day free trial. 60-day money back guarantee.
kte tab 201905

Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier

  • Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
  • Open and create multiple documents in new tabs of the same window, rather than in new windows.
  • Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!
officetab bottom
Say something here...
symbols left.
You are guest ( Sign Up? )
or post as a guest, but your post won't be published automatically.
Loading comment... The comment will be refreshed after 00:00.
  • To post as a guest, your comment is unpublished.
    Ronan K · 2 years ago
    Hi, Is there a way to make this formula not case sensitive for the lookup value, for example, if you are searching for the word "remove" it would count all instances of remove, Remove, REMOVE etc...
    • To post as a guest, your comment is unpublished.
      skyyang · 2 years ago
      Hello, Ronan,
      To count the number of a specific text without case sensitive, may be the below formula can help you:
      =(LEN(A2)-LEN(SUBSTITUTE(UPPER(A2),UPPER("remove"),"")))/LEN("remove")

      Please try it, hope it can help you!