How to insert a table of contents into a Word document

Susan Harkins shows you how easy it is to insert a table of contents into a Word document using the built-in default styles.

Long documents often include a table of contents near the beginning to direct readers to specific information. You might think that including a table of contents is difficult, but the feature is easy to implement. There are two steps. First, you identify the headings you want to include in the table of contents by applying built-in heading styles. Second, you generate the table of contents. I'll show you how to set it up using styles and then how generate the table. I'll also share a few important details about the resulting table.

Use built-in heading styles to id the headings

Below is a contrived example document that I created using =Rand() and adding heading text. Then, I used the Heading 1, Heading 2, and Heading 3 styles to format the headings. Word uses these built-in styles to generate a table of contents. (The figure's too small to actually read the text, but the text isn't important to the technique. You can create an example document of your own. You just need a few paragraphs of text and headings.) I applied Heading 1 to the first paragraph on both pages, Heading 2 to the second and third paragraphs on the first page and paragraph 2 on the second. The last paragraph heading style is Heading 3. If you don't want to include a heading in the table of contents, don't use one of the built-in heading styles to format it.

To apply a style, choose a Style from the Styles gallery, located in the Styles group on the Home tab. In Word 2003, choose a style from the Style dropdown on the Formatting toolbar. If you don't like the built-in styles, modify them appropriately for just the current document (not the underlying template).

TechRepublic's Microsoft Office Suite newsletter, delivered every Wednesday, is designed to help your users get the most from Word, Excel, and Access.

Generate the table of contents

After applying the appropriate heading styles to each heading, you're ready to generate the table of contents, as follows:

  1. Position the cursor where you want to insert the table of contents.
  2. Click the References tab. In Word 2003, choose References from the Insert menu, choose Index and Tables, and then click the Table of Contents tab.
  3. Click Table of Contents in the Table of Contents group and choose an option from the gallery.

The longer the document, the longer Word will take to generate the table of contents - but it shouldn't take very long. I used the first choice in the gallery, which increases the indent for each heading layer. In addition, Word inserted the table of contents into a content control and added a heading (Contents). If you choose the second gallery option, Automatic Table 2, Word will add "Table of Contents" as the heading.

I don't recommend choosing Manual Table unless you have a very specific reason for doing so. This option will insert a table of contents outline and you'll have to type in the actual text - I don't even know why Word offers this option. (If you use it, please tell us why!) To insert a second table of contents, choose Insert Table of Contents from the list below the gallery options.

Things to know

You're not stuck with the results, not exactly. You can change the font size and other attributes as follows:

  1. Click anywhere inside the table of contents (inside the content control).
  2. Click the References tab.
  3. From the Table of Contents dropdown, choose Insert Table of Contents. In Word 2003, choose References from the Insert menu and then select Table of Contents. Use the resulting dialog to alter the number of levels - the above example has three.
  4. To change the font, font size, font color, and so on, click Modify twice to display the Modify Style dialog. Make your changes via this dialog.
  5. After making changes, click OK three times.

I mentioned earlier that Word inserts the table of contents via a content control. When you move the mouse over the control, Word will display a shaded background. That shading won't print, it's just a visual reminder that the content is actually in a control and not ordinary content. If you don't see the shading in your document, do the following:

  1. Click the File tab and choose Options under Help. In Office 2007, click the Office tab, and then click Word options. Then click Advanced in the left pane. In Word 2003, choose Options from the Tools menu, and then click the View tab.
  2. In the Show Document Content section, change Set Field Shading to Always or When Selected. In Word 2003, you'll find the Field Shading option in the Show section.
  3. Click OK.

The table of contents won't update automatically if you add, delete, or change a heading. Remember, it's a content control (field). To update the table of contents, click inside the control and press [F9]. Or, click the control's Update Table option.

Removing a table of contents is difficult at best if you try to do it yourself using the mouse. It can be done, but it's tedious and aggravating. Instead, choose Remove Table of Contents from the Table of Contents option.


Susan Sales Harkins is an IT consultant, specializing in desktop solutions. Previously, she was editor in chief for The Cobb Group, the world's largest publisher of technical journals.

Editor's Picks