Skip to content

All Word’s Table of Contents options

Microsoft Word has many Table of Contents options, a lot of them hidden away. Here’s a complete list of all the switches available with a Word {TOC … } field code.

We’ve covered the basics of Table of Contents and some Table of Contents tricks already, here we’ll go in-depth with the TOC field codes themselves.

A TOC field code builds a table of contents, by collecting entries for a table of contents.  That’s normally using Heading styles but, as we’ll see, TOC can make a list based on other styles or outline levels or figures, charts, tables, TC fields, bookmarks or anything numbered by a SEQ field (Sequence field).

Word will insert a TOC field when you go to References | Table of Contents | Table of Contents but there’s a LOT more possible beyond the simple gallery that Microsoft offers.

Inside the TOC field code

Adding the TOC field into your document is easy. To insert a field code, use Ctrl + F9 and just use the syntax:

{TOC [switches]}

To toggle between viewing the field code and the results, simply press Alt + F9 on the keyboard.

Switches

The switches determine what is included in the table of contents.

\o “levels”

This switch will create a table of contents from paragraphs that are formatted with styles including outline levels, most commonly heading styles.

For example, {TOC \o “1-2”} will list paragraphs that have been formatted with styles through outline levels 1 – 2. You need to ensure the numbers are included in quotation marks.  If there is no range specified, it defaults to automatically include all levels in the document.

Below is an example of a table of contents that includes only Heading 1 and Heading 2 on the left, and then including Heading 3 and 4 as well on the right.

\t “Style,Level,Style,Level,…”

This switch creates a table of contents from paragraphs that are formatted with styles other than in-built styles.

For example, if you use the field code {TOC \t “Best Style 1,1, Best Style 2,2”} this will list paragraphs that have been formatted with styles “Best Style 1” (as level 1) and “Best Style 2” (as level 2).

In other words, you’re assigning outline levels to particular styles but only for making up a Table of Contents.

These are custom styles that were created for our document’s example. The number after each style name just indicates the table of contents entry level that corresponds to that particular style.

You can use both \t and \o switches to build a table of contents incorporating both built-in and custom styles.  

\u

This switch will create a table of contents from paragraphs whose formatting includes outline levels applied directly, in paragraph settings.

What is an outline level in paragraph settings?

If you go to Home | Paragraph | Paragraph Settings (the little arrow in bottom right corner)

Under General | Outline Level you can choose the level in the drop-down menu. Any of these levels are included in the field code.

\c “SEQIdentifier”

This switch will create a table of contents that lists figures, charts, tables, or other items numbered by a SEQ field (Sequence field). The SEQidentifier, which corresponds to the caption label should match the identifier in the SEQ field.

For example, if you use the field code {TOC \c “tables”} this will list all numbered tables. 

\a Identifier

This switch will create a table of contents that lists items captioned with the caption command, but excludes caption labels and numbers.

For example, using the field code {TOC \a figure} will list the name of the caption, but omit the Figure number. E.g. “Figure 1: Shapes” on page 51 will display:

You can use both \c and \a switches to build a table of contents with both labels and numbers.

\f EntryIdentifier

This switch will create a table of contents from TC fields. The table is constructed only from TC fields with the same identifier (usually a letter) if the EntryIdentifier is given.

For example, { TOC \f t } builds a table of contents from TC fields such as { TC "Chapter Entry" \f t }.

\l Levels

This switch will create a table of contents from TC fields that assign entries to a specified level/s.

For example, { TOC \ l 1-3 } will create a table of contents from TC fields that are assigned to levels 1-3. TC fields that assign entries to lower levels are omitted.

\b BookmarkName

This switch creates a table of contents, collecting only entries marked by a specified bookmark. 

Basics of Table of Contents
Table of Contents tricks
Finding the Style Separator feature for Word TOC’s 
Choose the words to show in a Word Table of Contents 
Four tricks to shrink a Table of Contents in Word 

About this author

Office-Watch.com

Office Watch is the independent source of Microsoft Office news, tips and help since 1996. Don't miss our famous free newsletter.