Creating an Index in Word

Most long documents have an index. An index lists the ideas, topics, and terms discussed in the tome, so people can find the information they seek more easily. The good news is that adding an index to your document makes it vastly more useful to your readers. The bad news is that creating an index is a time-consuming and potentially challenging process. Although Microsoft Word includes the tools you need to create an index, the usefulness of the end product depends more on the person creating the index than on Word itself.

Know Thy Document

Before you start in on the mechanics of dealing with the index in Word, think about your document. If you are the author, it can be helpful to keep a list of terms and concepts off in a list somewhere as you are writing. If you aren’t the author, it’s helpful to just print out the document first and highlight potential index entries.

The goal is to gather up a lot of of the terms you’ll enter into the index. Look for nouns for subject entries and verbs for procedural information. You’ll notice that for procedures, most indexes use the -ing form of the verb, such as “copying files” rather than “copy files.”

After you have a list of words, think of synonyms and ways people might look up the information. Those can be “see also” type entries like “how to copy files, see deleting files” or “making copy of files, see deleting files.”

Add Entries

In Word, creating an index is a two-step process. First you add the entries throughout the text and then you generate the index itself. Word goes through the document and collects the entries into a list with the page numbers. If you’ve read the online help, you may have read about creating a “concordance file” that automatically marks index entries. It sounds like it would be a cool thing, but generally it’s more trouble than it’s worth because it’s essentially a giant search activity. Only a human can determine when terms are contextually relevant.

For example, suppose you have a book about dog training. You might have an entry that points to a section on dealing with problem barking. If you did a concordance, Word would go through and find every time you used the word bark or barking. Now consider how many entries it would find that aren’t relevant. Dogs bark for a lot of reasons. Deleting all the entries the concordance marked incorrectly is probably more work than just doing the index entries in the first place.

The XE Field

To create indexes, it helps to spend some time learning about fields. You use the Index Entry (XE) field to mark the text you want to incorporate into the index. This situation is one where you really should learn the keyboard shortcut. (The menu item is so deep it’s absurd.) So to mark entries, follow these steps:

1.  Highlight a word or words you want to add as an index entry. Or you can enter different text by placing the insertion point where you want the XE field code.

2.  Press Alt+Shift+X. The Mark Index Entry dialog box appears.

3.  If you highlighted text, it appears in the Main Entry box. Otherwise, type your first-level index entry text. You also can type a second-level entry in the Subentry box. If you need a three-level index, you can follow the subentry text with a colon and type the third-level entry text.

4.   Click Mark. The Mark Index Entry dialog box stays open, so you can add more entries.

The way you add your index entries affects how they appear in the index. For example, if you put Kennedy, John in the Main Entry field, you’d end up with an index entry that looks like this:

Kennedy, John, 7

You can create each entry individually and just ignore the subentry field if you want. When you show field codes, you see that the field looks like {XE “Kennedy,John”} in the text. Note that the comma in there is the one you typed in.

However, if you put Kennedy in the Main Entry Field and John in the Subentry field, you get:


John, 7

If you add entries for other Kennedys such as Robert and Rose too, together they’d look like:


John, 7

Robert, 9

Rose, 10

The fields you see in the text would be {XE “Kennedy:John”}, {XE “Kennedy:Robert”}, and {XE “Kennedy:Rose”}. Note that the last name and first name are separated by a colon. When you use the subentry field, you need to be careful that the text in the main field is exactly the same for similar entries. For example, in this case, if you spelled Kennedy wrong in an entry, you’d get an extra entry with the misspelling. Misspellings can be really subtle too. The entries must match exactly. You can’t have extra spaces or change the case. Word treats “rose” and “Rose” as two different entries. And “Rose Kennedy” (one space in between the words) is not the same thing as “Rose Kennedy” (two spaces in between the words).

As soon as you begin marking entries, Word shows field codes and hidden text, so you can see what’s going on and make sure you have entered the entries correctly.  XE “fred” However, it’s sort of confusing because showing the index entries actually expands out your document, so the page numbers may seem wrong. Be sure you hide field codes and hidden text before you generate your index. Choose Tools|Options and in the View tab, remove the checkmarks next to Field codes and Hidden Text.

Generate the Index

After you have defined all your index entries, you are ready to generate your index. In a short document, you can just add the INDEX field at the end of the document by choosing Insert|Index and Tables or Insert|Reference|Index and Tables, depending on your version of Word.

You can choose from an Indented (sometimes called “nested”) or a Run-in Index. Basically, the Indented index looks somewhat like an outline.

allergies (see also skin and coat)
contact dermatitis 228-229
flea-bite sensitivity 227-228
food allergies 227-228

In contrast, a run-in index appears in a paragraph format like so:

Dogs: allergies, 129; breeds, 188;
difference from cats, 210; housebreaking, 300

After you generate the index, it’s virtually guaranteed that you’ll find mistakes. So you need to go back and change the entries that have problems. Although it’s tempting, don’t edit your generated index. If you regenerate the index, your changes disappear. So you need to go back and edit the entries directly.

To edit the entries, you need to have hidden text showing. You can modify the index entry text directly by changing the text inside the quotation marks. If hidden text isn’t showing press Ctrl+Shift+8 or press the Show/Hide button on the Standard toolbar, which is the one that looks like a paragraph icon. With hidden text showing, you also can use Word’s Search feature to find a particular entry. Press Ctrl+F and click the More button. Click Special and then select Field. You’ll see that ^d appears in the Find What box. If you have other types of fields in your document, put ^d X into the box and it will hop to the next field that starts with X. (And it’s probably an XE index entry field!) If you know the entry name, add it too in quotes, such as ^d XE “storm”.

If you want to delete an entry entirely, you have to delete the entire field code. Select the entry including the braces and press the Delete key.

After you make your changes, regenerate your index by clicking in it and pressing F9 to update fields.

If you don’t like how your index looks from a formatting standpoint, you can change the built-in Index 1 through Index 9 styles so they match your document. This process is much like editing the Table of Contents styles. The styles correspond to the index level.

About Susan Daffron

Susan Daffron is the author the Alpine Grove Romantic Comedies and multiple award-winning nonfiction books, including several about pets and animal rescue. Check out all her books on her Amazon Author page.