How to Count Characters in a Cell Including Spaces in Excel – 3 Methods

The dataset showcases movie names.

excel count characters in cell including spaces


Method 1 – Using the LEN Function

  • Select a cell to show the count.
  • Enter the formula in the cell:
    =LEN(B5)
    Replace B5 with the cell containing characters.
  • Press Enter.
    It will return the character count including spaces.
  • Drag the Fill Handle to apply the formula to the rest of the cells.

This is the output.

Count Characters in Cell Including Spaces in Excel

Read More: How to Count Specific Characters in a Cell in Excel


Method 2 – Combining Functions to Count Characters in a Range Including Spaces

2.1. Using the LEN Function

  • Select a cell to see the count.
  • Use the formula in the cell:
    =LEN(B5)+LEN(B6)+LEN(B7)+LEN(B8)+LEN(B9)
    Replace B5, B6, B7, B8, and B9 with the selected cells.
  • Press Enter.

This is the output.

Count Characters in Cell Including Spaces in Excel

Read More: How to Count Characters in Cell without Spaces in Excel

2.2. Combining the SUM and the LEN Function

  • Select a cell to see the count.
  • Use the formula in the cell:
    =SUM(LEN(B5:B9))
    Replace B5:B9 with the selected cell range.
  • Press Enter.

This is the output.

Count Characters in Cell Including Spaces in Excel

Alternatively:

  • Select a cell to see the count.
  • Use the formula in the cell:
    =SUMPRODUCT(LEN(B5:B9))
    Replace B5:B9 with the selected cell range.
  • Press Enter.

This is the output.

Count Characters in Cell Including Spaces in Excel


Method 3 – Counting Characters Excluding Leading & Trailing Spaces

 

Count Characters in Cell Including Spaces in Excel

 

  • Select a cell to show the count.
  • Use the formula in the cell:
    =LEN(TRIM(B5))
    Replace B5 with the selected cell.
  • Press Enter.
  • Drag the Fill Handle to apply the formula to the rest of the cells.

This is the output.=LEN(TRIM(B5))

Read More: How to Count Space Before Text in Excel


Download Practice Workbook


Frequently Asked Questions

How Do You Count the Occurrences of a Character in a Cell in Excel?

Use the SUBSTITUTE and the LEN function. If the data is in A1 and the character is x, use the formula in any cell: =LEN(A1) – LEN(SUBSTITUTE(A1, “x”, “”))

Press Enter to see the result.

How Do I Count the Number of Spaces in a Cell in Excel?

Enter this formula in any cell and press Enter: =LEN(A1) – LEN(SUBSTITUTE(A1, ” “, “”))

Replace A1 with your data.

What is the Maximum Number of Characters I Can Show in an Excel Cell?

You can show 1024 characters in a cell and it can contain a maximum of 32767 characters. The Formula Bar can show the 32767 characters at the same time.


Related Articles


<< Go Back to Count Characters in Cell | String Manipulation | Learn Excel

Get FREE Advanced Excel Exercises with Solutions!
Asif Khan Pranto
Asif Khan Pranto

Md. Asif Khan Pranto worked as an Excel and VBA Content Developer in Exceldemy for over two years and published some articles for the website. He is passionate about exploring new aspects of Excel and VBA. He received his Bachelor of Science in Mechanical Engineering from the Islamic University of Technology. Now, he is pursuing a Master of Development Studies to experience a new spectrum of knowledge. Apart from creating Excel tutorials, he is interested in Data Analysis... Read Full Bio

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo