In this post, I'll share how to build a dynamic Microsoft Word index (i.e. one you can update automatically without having to rebuild it) using 2 methods - the Mark and Index method and using a concordance file.
A Word Index (example shown below) provides a very useful reference for the reader.
Unlike a structured table of contents where the reader scans a general list of topics until they find a one of interest), a Word index allows the reader to search for a specific word or phrase, normally in alphabetical order and go straight to the relevant page (or pages).
RELATED POST:
How to create a table of contents in Word that updates itself
RELATED POST:
How to set up multilevel numbering that works perfectly first time
1. Creating a Word Index using Mark & Index
There are two steps for generating an index. Firstly, you must work through your document and ‘mark’ anything that you would like to include in the index. Then, you compile the index, using the marked entries.
Each time you mark an entry, an XE field code is inserted into the document, like this:
{ XE “index entry text” }
XE stands for Index Entry.
Word switches hidden formatting on as soon as you mark an entry so it doesn't take long before your document starts to look messy. But don't worry - when you print your document, field codes are not printed.
But don't worry - when you print your document, the field codes are not printed.
As your Word index grows, It can sometimes be quite hard to locate and isolate a particular index entry to modify or remove it.
For this reason, many editors use a concordance file, which is a table in a separate document that lists everything to be indexed. This file can then be used to compile the index, leaving the original file squeaky clean and making maintenance easy.
(a) Marking a main entry
To mark an entry:
1. Highlight the text that should appear in the index.
2. In Word, select the References tab.
3. Click the Mark Entry icon in the Index group
The Mark Index Entry dialog box is displayed. The text that you highlighted is displayed in the Main Entry box. This is the text that will appear in the index. You can modify it if you wish.
It’s worth learning the keyboard shortcut for marking entries, as you will probably use it a lot when working with large documents. To display the Mark Index Entry dialog box, press
ALT + SHIFT + X
4. Click the Mark button to mark only this occurrence of the word or phrase
Click the Mark All button to flag every occurrence of the word or phrase within the document.
5. Rinse and repeat for each word or phrase you want to include in the index. To save time, you can leave the Mark Index Entry dialog box open – you don’t need to close it for every entry you select a new entry.
An XE field code is inserted into the document
{ XE “index entry text” }
The text within the quotation marks is what appears in the index. It does not have to be the same as the text in the document so you can edit it if you wish.
* Guidelines for marking index entries in Word *
(b) Marking a subentry
Subentries are a powerful way of grouping similar items in an index. Let’s say we wanted to index various sub-entries around the main word Console:
If the reader searches the index for Console, they can be redirected to the page(s) for the specific console they are interested in.
In this example, the Main Entry is Console and the 3 subentries are 3DS, Switch and Game Boy.
1. Find the word 3DS in the text and select it.
2. Press Alt+ Shift + X
3. Enter 'Console' into the Main Entry and '3DS' into the Subentry. Entries will appear in the index exactly as you type them so take care not to misspell anything and be consistent with upper case and lower case.
4. Click the Mark or Mark All buttons.
(c) Cross-referencing another indexed item
Cross-references are used to direct someone who is searching for one thing to another. For example, if someone searches for Music, the index could say See Audio, or if someone searches for Food, the index could point them towards Nutrition.
Index cross-references should not be confused with the standard Word cross-reference feature which can be found on the Insert menu.
To create an index cross-reference:
1. Select the text to be marked.
2. Press ALT + SHIFT + X
3. Confirm the text in the Main Entry box.
4. Select the Cross-Reference radio button.
5. After “See” type the synonymous text item.
(d) Compile the Word Index
Now that all the entries have been marked it is time to create the index itself.
1. Select the References tab.
2. Click the Insert Index icon in the Index group. The Index dialog is displayed.
3. Choose a Format from the drop-down list. Be aware that different formats select, deselect or change some of the other options in the dialog. The safest approach is to start at the bottom left and work upwards, then to the right.
4. Ensure that Right-align page numbers is selected.
5. Select a tab leader (the tab leader fills the gap between the end of the item and the page number - dots work best).
6. Choose whether to use Run-In or Indent (watch the preview).
7. Choose how many columns to display in the index.
8. Click OK
(e) Update the index (whenever needed)
1. MIn the document, mark any new text you wish to include in the index and remove any existing XE field codes that you no longer require.
2. Click anywhere on the index to show grey shading.
3. Press F9 to refresh the index.
Alternatively, right-click and choose Update Field from the context menu or click the Update Index button on the References ribbon).
RELATED POST:
How to create a table of contents in Word that updates itself
2. How to remove all field codes from a document
Ideally, a document should be finished before creating an index, but if significant changes have occurred you may want to clear any XE field codes throughout the document and start from scratch. Here's a simple process to get that job done.
1. Press CTRL H to display the Replace dialog. Alternatively, click the Find & Select icon on the far-right side of the Home ribbon, then choose Replace.
2. In the Find box, type ^d (press SHIFT 6 to get ^).
3. Leave the Replace box empty.
4. Click Replace All (or Find then Replace to process one by one).
Using ^d will remove every field in the document, not just the XE field codes. It is a special character that finds braces (curly brackets) that enclose field codes.
To remove just the XE field codes, use ^d XE.
3. How to create a Word index using a concordance file
Many editors use a concordance file to generate an index for a document. A concordance file is a two-column table that is created in a separate document.
(a) Mark entries within a Word document using the pre-prepared concordance file
1. Select the References tab.
2. Click the Insert Index icon in the Index group.
3. Click the AutoMark.. button.
4. Locate and select the concordance file and click OK . All entries are now marked.
(b) Create the index
1. Select References | Insert Index again.
2. Set your index preferences as discussed in Step 2: Compiling the index (above).
3. Click OK.
(c) Update the concordance and/or index
1. Open the concordance file, make your changes and save the file.
2. Clear the current XE codes in the main document (as described previously).
3. Select References | Insert Index | Automark.
4. Click on the existing index to display the grey shading.
5. Press F9 to refresh the index.
Alternatively, right-click and choose Update Field from the context menu or click the Update Index button on the References ribbon).
4. Key Takeaways
And that, my friend, is how you build an index page in Word.
RELATED POST:
How to set up multilevel numbering that works perfectly first time
I hope you found plenty of value in this post. I'd love to hear your biggest takeaway in the comments below together with any questions you may have.
Have a fantastic day.
About the author
Jason Morrell
Jason Morrell is a professional trainer, consultant and course creator who lives on the glorious Gold Coast in Queensland, Australia.
He helps people of all levels unleash and leverage the power contained within Microsoft Office by delivering training, troubleshooting services and taking on client projects. He loves to simplify tricky concepts and provide helpful, proven, actionable advice that can be implemented for quick results.
Purely for amusement he sometimes talks about himself in the third person.
SHARE
Thank you! You sure made it easier.
Thank you Rupila.
This has been a very useful tutorial. One thing I still don’t know – it’s normal in book indexes to show the list of pages like this:
3, 6, 8-11, 14, 22.
rather than
3,6,8,9,10,11,14,22
How do I get word to index like this?
Hi Chris
1. In the document, select the full range of text across each page in the range that you want to appear in the index (e.g all the text on pages 9-11).
2. On the Insert ribbon, click the Bookmark icon, type a valid name for the bookmark and click Add.
3. [Anywhere in the document] Press Alt Shift X to display the Mark Index Entry dialog.
4. Type a name for the index item.
5. Select the Page Range option and select your bookmark from the dropdown list.
6. Click Mark. You should see something like { XE “Index item” \r “Bookmark_Name” }.
7. Generate or refresh your index. The index should show something like Index item …………. 9-11.
8. For situations where an indexed item appears on pages 1-3 and 9-11, select all the text in the second page range and add a bookmark with the same name. When you refresh the index, BOTH page ranges appear in the index.
I hope that helps (and sorry for the late reply).