An Overview of LEN Function | Microsoft Excel

The LEN function is one of the text functions in Microsoft Excel. You can use it as a standalone function as well as in collaboration with the other functions. This article will give you an overview of the LEN function in Excel.

Objectives

The LEN function determines the length of a text string. It returns the length of the string as the number of characters.

Syntax

=LEN(text)

Arguments

  • text: Compulsory. It refers to the string whose length you want to determine.

Output

Returns the length of the string as the number of characters.

Examples of LEN Function

Suppose, you have a string “John Doe” in cell A2. Now you want to find its length. To do that you can use the LEN function. The formula for this will be :

=LEN(A2)

The output will be 8.

Here are some examples of the usage of the LEN function.

Examples of LEN Function in Excel

Usage Guide of LEN Function

Step_1: Start with inserting an equal sign (=) in a blank cell.

Step_2: Then type LEN.

Step_3: Type open parenthesis “(“.

As you type the open parenthesis, Excel shows the syntax of the LEN function.

Step_4: Insert the string whose length you want to determine.

You can directly insert a string into the function. If you want the string to be John Doe, you have to type John Doe inside a pair of double inverted commas like “John Doe”.

You can also insert a cell address that contains a string.

Here, I’m inserting A2 which has the string, John Doe.

Step_5: Insert the closing parenthesis “)”.

Step_6: Finally, hit the ENTER button to insert the formula inside the cell.

Final Result

Usage Guide of LEN Function in Excel

The LEN function returns 8. Here, the value of text is John Doe. There are 7 LETTERS and 1 SPACE in John Doe. “SPACE” also counts as a character. So, the length of text is 8.

Availability

  • Excel for Microsoft 365
  • Excel 2016
  • Excel for Microsoft 365 for Mac
  • Excel 2016 for Mac
  • Excel for the web
  • Excel 2013
  • Excel 2021
  • Excel 2010
  • Excel 2021 for Mac
  • Excel 2007
  • Excel 2019
  • Excel for Mac 2011
  • Excel 2019 for Mac
  • Excel Starter 2010

Remarks

  • The LEN function counts LETTERS, NUMBERS, COMMA, SPACE, NEGATIVE SYMBOL(-), DECIMAL SEPARATOR(.), and other SPECIAL CHARACTERS as characters. But NUMBER FORMATTING is not included.
  • It returns 0 when the value of the text is empty.
  • The LEN function is not case-sensitive.
  • It treats DATES as a 5-digit serial number.
  • The LEN function can only be used to calculate the length of a text string that is up to 32,767 characters long.
  • It can be used in combination with other functions, such as LEFT, RIGHT, and MID, to extract a specific number of characters from a text string.

Conclusion

The LEN function is one of the text functions in Excel. If you have any questions regarding the LEN function, please comment below. Thanks!

Rate this post

Leave a Reply

Your email address will not be published. Required fields are marked *