Calculating Average Word Length

by Allen Wyatt
(last updated August 5, 2017)

Denise knows how to figure out the number of words in a document using the tools that Word provides. She wonders, though, if there is a way to figure out the average word length for a selection of text or for an entire document.

There are a variety of ways you can go about this task. One approach is to rely on tools already built into Word. For instance, on the Review tab of the ribbon there is a Word Count tool. Click it, and you'll see the Word Count dialog box. (See Figure 1.)

Figure 1. The Word Count dialog box.

Using the information in the dialog box, you can easily calculate an average word length. You'll want to use the character count that doesn't include spaces, divided by the number of words.

It is also interesting to note that if you have your status bar configured to show the document word count, you could also click on the number of words shown there and Word displays the full Word Count dialog box. (If you don't have the status bar configured to show a word count, you can right-click on the status bar to modify what is shown there.)

Another approach is to enable the readability statistics for Word. You do this by following these steps:

  1. Display the Word Options dialog box. (In Word 2007 click the Office button and then click Word Options. In later versions of Word display the File tab of the ribbon and then click Options.)
  2. At the left side of the dialog box click Proofing. (See Figure 2.)
  3. Figure 2. The Proofing options of the Word Options dialog box.

  4. Make sure the Check Grammar with spelling check box is selected.
  5. Make sure the Show Readability Statistics check box is selected.
  6. Click on OK.

With this configuration change made, go ahead and run a spelling and grammar check (press F7). Word does its check and prompts you, as necessary, about any changes you might want to make. When the check is done, Word displays the Readability Statistics dialog box. (See Figure 3.)

Figure 3. The Readability Statistics dialog box.

Note that the dialog box includes an Averages section. You can see here not only the average word length, but also other averages for the text. If you run the spelling and grammar check on the entire document, you get statistics for the entire document. If you want them for only a portion of the document, select that portion before starting the spelling and grammar check.

If you want to put the average word length into your document, you can rely on fields to do the work for you. This particular approach relies on three fields: =, NUMCHARS, and NUMWORDS:

{ = { NUMCHARS } / { NUMWORDS } }

Note that each pair of field braces is inserted in your document by pressing Ctrl+F9. Within the braces you can type the field names, as shown above. When you update the field (F9), you'll se the calculated average word length.

Still another approach is to use a macro to do the calculations. This is made possible because Word, in VBA, keeps track of both characters and words in a selection.

Sub AvgWord()
    Dim dAvg As Double

    If Selection.Type <> wdSelectionIP Then
        ' A text selection has been made
        dAvg = Selection.Characters.Count / Selection.Words.Count
    Else
        ' No selection, so use entire document
        dAvg = ActiveDocument.Characters.Count / ActiveDocument.Words.Count
    End If
    MsgBox "Average word length is " & Format(dAvg, "0.00") & " characters"
End Sub

Note that the macro uses the Type property of the Selection object to determine if there is a text selection at the time the macro is run. If so, then the calculation is performed using whatever is selected; if not, then the entire document is used for the calculation. You can, of course, assign a shortcut key to the macro or you can add it to your Quick Access Toolbar for handy access.

There is one caveat that I should draw to your attention—it seems that Word, in each of the ways described in this tip, often returns different counts. For instance, if you look back at the Word Count dialog box, you can see a check box that controls whether Word includes text boxes, footnotes, and endnotes in the statistics. The other methods don't offer that flexibility; they seem to return counts that don't include the text boxes, footnotes, or endnotes. Plus, the macro-based approach seems to use a different way to count words than the other methods.

The upshot of this is you shouldn't be surprised if you get slightly different results with each method discussed. Pick a method that works best for you and your needs, and understand that the result is, at best, approximate.

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (3895) applies to Microsoft Word 2007, 2010, 2013, and 2016.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He  is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Preserving the Undo List

The undo list can be a lifesaver when working in a macro. Unfortunately, the undo list is not preserved when you run a macro. ...

Discover More

Automatically Converting to GMT

You know what time it is, right? (Quick—look at your watch.) What if you want to know what time it is in Greenwich, ...

Discover More

Enforcing a Do-Not-Use Word List

Got a list of words you don't want to appear in your documents? There are a number of ways that you can make sure they don't, ...

Discover More

Create Custom Apps with VBA! Discover how to extend the capabilities of Office 2013 (Word, Excel, PowerPoint, Outlook, and Access) with VBA programming, using it for writing macros, automating Office applications, and creating custom applications. Check out Mastering VBA for Office 2013 today!

More WordTips (ribbon)

Adjusting the Size of Ribbon Icons

Do you feel like the icons on the ribbon take too much screen space? Your options in reducing that "icon footprint" may be ...

Discover More

Hiding and Displaying Hidden Text

You can easily hide text by simply changing the attributes associated with the text. Once that is done, you can turn the ...

Discover More

Jumping to a Relative Section

Navigating through a long document can be challenging, at times. Here's a way you can move forward or backwards in your ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is five more than 2?

There are currently no comments for this tip. (Be the first to leave your comment—just use the simple form above!)


This Site

Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.