You added a table of contents to your Word document, but the page numbers or headings no longer match the actual content. This happens because a TOC is a field code, not a static list, so it does not refresh automatically when you edit headings or add new pages. This article explains how to update the entire table of contents or just the page numbers in Word for Windows and Mac, and what to do when the Update Table button is grayed out or missing.
Key Takeaways: Updating a Table of Contents in Word
- Right-click the TOC > Update Field: Quickest way to refresh page numbers and headings in any Word version.
- Ctrl + A then F9: Keyboard shortcut to update all TOC fields in the entire document at once.
- File > Options > Display > Update fields before printing: Forces Word to refresh the TOC automatically each time you print.
What Causes a Table of Contents to Go Out of Date
A table of contents in Word is not a static snapshot. It is a field code that reads heading styles Heading 1, Heading 2, and Heading 3 and their page numbers. When you add, remove, or reorder headings, or when text shifts to a different page, the TOC field no longer reflects the current state. Word does not update the TOC automatically because doing so would slow down editing in long documents. You must trigger the update manually or configure Word to update it before printing.
How the TOC Field Works
When you insert a TOC using the References tab, Word inserts a { TOC } field code. This field scans the document for text formatted with built-in heading styles and collects the heading text and page number. The field stores the result as a list. Editing the document does not change the stored result until you update the field.
Prerequisites for a Successful Update
Before you update the TOC, make sure all headings in your document use the built-in heading styles Heading 1, Heading 2, Heading 3, and so on. Custom paragraph styles that are not mapped to a heading level will not appear in the TOC, even after an update. Also confirm that field codes are enabled in Word. Go to File > Options > Advanced and under Show document content, ensure Field shading is set to Always or When selected. This setting does not affect the update process but helps you see which parts of the document are fields.
Steps to Update the Table of Contents Manually
You can update the TOC using the mouse or the keyboard. Both methods produce the same result.
- Click inside the table of contents
Place the cursor anywhere inside the existing TOC. The entire TOC area becomes shaded to indicate it is a field. - Press F9 on the keyboard
On Windows, press the F9 key. On a Mac, press Fn + F9 if the function keys are set to control system features. The Update Table of Contents dialog box opens. - Choose what to update
Select Update page numbers only if you only changed page breaks or added text that shifted headings to new pages. Select Update entire table if you added, removed, or renamed headings. Click OK.
Alternatively, right-click the TOC and select Update Field from the context menu. The same dialog box appears. This method works on both Windows and Mac.
Update All TOC Fields in the Document at Once
If your document contains multiple tables of contents such as a main TOC and a separate table of figures, you can update all of them in one action.
- Select the entire document
Press Ctrl + A on Windows or Command + A on Mac. - Press F9
Word updates every field in the selection, including all TOC fields, table of figures fields, and cross-reference fields. Each TOC displays its own Update Table of Contents dialog. Click OK for each one.
Automate TOC Updates Before Printing
You can configure Word to update all fields, including the TOC, every time you print or preview the document.
- Open Word Options
Click File > Options. In the Word Options dialog, click Display. - Enable update before printing
Under Printing options, check Update fields before printing. Click OK.
With this setting enabled, Word updates the TOC automatically each time you go to File > Print or press Ctrl + P. The TOC is updated silently in the background. You do not see the Update Table of Contents dialog. Word uses the Update entire table behavior by default.
Common Issues When Updating a Table of Contents
The Update Table Button Is Grayed Out
The Update Table button on the References tab is grayed out when the cursor is not inside a TOC field. Click anywhere inside the TOC to activate the button. If the button remains grayed out, the TOC may have been converted to static text. To check, right-click inside the TOC. If you see Update Field in the context menu, it is still a field. If you see only Cut, Copy, and Paste, someone manually typed the TOC or used Paste Special to remove the field code. You must delete the static text and insert a new TOC from the References tab.
Page Numbers Do Not Update After F9
If you choose Update page numbers only but the numbers still look wrong, the document may contain manual page breaks or section breaks that shifted content. Select Update entire table instead. If that still fails, press Ctrl + A then F9 to force a full refresh of all fields. On rare occasions, the heading style itself may have been modified to suppress page numbers. Check the heading paragraph formatting and remove any hidden or suppressed page number settings in the paragraph dialog.
Headings Missing From the Updated TOC
A heading does not appear in the TOC after an update when the heading text is formatted with a custom style instead of a built-in heading style. Select the missing heading text, go to the Home tab, and apply the correct Heading 1, Heading 2, or Heading 3 style. Then update the entire TOC. If the heading uses a built-in style but is still missing, the style may have been set to an outline level of Body Text. Right-click the heading, select Paragraph, and under Outline level, choose Level 1, 2, or 3 to match the heading level.
TOC Shows “Error! Bookmark Not Defined”
This error appears when the TOC field cannot find a bookmark that was used to build the TOC entry. It usually happens after you copy a TOC from another document or after you delete a heading that was referenced by a cross-reference field that is also inside the TOC. To clear the error, update the entire TOC by pressing F9 and choosing Update entire table. If the error persists, delete the TOC and insert a new one from the References tab.
Manual Update vs Automatic Update: Key Differences
| Item | Manual Update | Automatic Update Before Print |
|---|---|---|
| Trigger | Press F9 or right-click > Update Field | Word applies update when you click File > Print or press Ctrl + P |
| User control | Choose page numbers only or entire table each time | Word uses Update entire table, no user choice |
| Visibility | Dialog box appears, user sees the update | Update happens silently, no dialog |
| Best for | Editing sessions where you need to verify changes | Final review and printing to ensure accuracy |
You can now update a table of contents in Word using the F9 key, the right-click menu, or the References tab button. Set the print option to update fields automatically so you never send a document with outdated page numbers. For documents with multiple TOC fields, use Ctrl + A then F9 to refresh everything at once. If a heading still does not appear after an update, verify that the heading style is a built-in heading style and that its outline level matches the intended TOC level.