Count words in a range of cells or columns in Excel and Google Sheets

={SUM(IF(LEN(TRIM(A2:A5))=0,0,LEN(TRIM(A2:A5))-LEN(SUBSTITUTE(A2:A5," ",""))+1))}

A:2:A5 = Range

ArrayFormula use "Ctrl+Shift+Enter"

Check below for a detailed explanation with pictures and how to use formulas in Excel and Google Sheets.

Count words in a range of cells or columns in Excel

How to count words in a range of cells or columns in Excel?

COUNT WORDS IN A RANGE OF CELLS OR COLUMNS — EXCEL FORMULA AND EXAMPLE

={SUM(IF(LEN(TRIM(A2:A5))=0,0,LEN(TRIM(A2:A5))-LEN(SUBSTITUTE(A2:A5," ",""))+1))}

💡 ArrayFormula use "Ctrl+Shift+Enter"

Count words in a range of cells or columns in Google Sheets

How to count words in a range of cells or columns in Google Sheets?

COUNT WORDS IN A RANGE OF CELLS OR COLUMNS — GOOGLE SHEETS FORMULA AND EXAMPLE

=ArrayFormula(SUM(IF(LEN(TRIM(A2:A5))=0,0,LEN(TRIM(A2:A5))-LEN(SUBSTITUTE(A2:A5," ",""))+1)))

💡 ArrayFormula use "Ctrl+Shift+Enter"

Other useful "COUNT FUNCTIONS: TEXT BASED CRITERIA" formulas in Excel and Google SheetsOthers FormulasDate and time functionsNumber based criteriaExtract functions