This quick tutorial explains the steps required to Count Words in LibreOffice Calc Cell.
There are no direct features available in LibreOffice that can help you to count words. In the early article, I explained how to count characters in LibreOffice Calc. In this guide, we count the words.
Count Words in LibreOffice Calc Cell
There is no specific way. This can only be achieved by combining some formulas in a Calc cell. The words in a sentence, in general, are separated by one single space, i.e. ” “.
Let’s do it via an example.
I have the following data in a Calc sheet in Column A.

The words are separated by a space. So, here’s a summary of the logic which we want to implement:
- Remove any leading and training spaces
- Count the length of the sentence
- Count the length without the spaces
- Subtract the above two values and add 1. Because for a minimum of two words, there is one space!
- Use TRIM() and LEN() functions to achieve points #1 and #2.
- Use SUBSTITUTE to remove ” ” single space with “” empty string.
- The final count of words in Column D is subtracting and adding 1.
So, if you combine them, the following formula would give you the count of words in LibreOffice Calc cell.
=LEN(TRIM(A1))-LEN(SUBSTITUTE(TRIM(A1)," ",""))+1
In the above formula – change A1 as per your need.

I hope this gives some guidance on how you can Count Words in a spreadsheet. You can modify the above idea and achieve the desired result by combining the concept with other means.
Let me know in the comment section below if you are facing errors. And don’t forget to mention if it helped you.
Cheers.

I’m trying to find the first word in a cell, and the last word as a separate result
I would search for the text before the first space / after the last space, but can find no way of doing this with Calc.
Any help or suggestions would be deeply appreciated
You can get the first word by the below formula. But to get the last word is super complex. I need to do some research.
=LEFT(A1,FIND(” “,A1)-1)
Thank you, a word counter is just what I needed!