Fix Word Error: Creating a Table of Contents Start by Applying a Heading
Question details
The user is unable to generate a table of contents and receives an error prompting them to apply a heading style, even after attempting to format the document.

- Product
- Word
- Device & OS
- not provided
- Scenario
- Generating a table of contents for a structured document.
- Observed behavior
- Word displays the message "Creating a Table of Contents? Start by applying a heading from the Style Gallery to the selected text" and fails to build the TOC.
Ensure you have highlighted only the specific titles or section names you want to appear in the table of contents, rather than applying styles to large blocks of regular body text.
Apply Built-in Heading Styles to Specific Text
The most common cause of this error is applying heading styles to the entire document or not using the recognized built-in headings.
For a Table of Contents to generate automatically, the word processor relies on predefined outline levels. Built-in headings (like Heading 1, Heading 2) already have these levels assigned. If these styles are accidentally applied to the entire text body, or not applied at all, the TOC generator will either fail with an error or pull in the entire document.
Highlight only the text, such as a chapter title or section header, that you want to appear in the table of contents.
Navigate to the Home tab and select Heading 1, Heading 2, or Heading 3 from the Styles gallery.
Highlight your regular paragraph text, go to the Home tab, and ensure it is set to the 'Normal' style, not a heading style.
Navigate to the References tab, click Table of Contents, and choose an automatic style to insert your TOC.

Assign Outline Levels to Custom Styles
If you are using custom styles instead of built-in headings, Word won't automatically include them in the TOC unless they are assigned a specific outline level.
Create a Table of Contents Effortlessly in WPS Writer
WPS Writer offers an intuitive style gallery and seamless table of contents generation. It perfectly handles Microsoft Word document formats (DOCX) while making document structuring straightforward and error-free.
- 1. Highlight your heading: Select the chapter or section title in your document.
- 2. Apply a heading style: Go to the Home tab and click Heading 1, Heading 2, or Heading 3 from the style ribbon.
- 3. Generate the TOC: Navigate to the References tab and click Table of Contents.
- 4. Select layout: Select your preferred automatic TOC layout from the dropdown to insert it instantly.

Frequently Asked Questions
Why does my entire document show up in the Table of Contents?
This happens when a heading style is accidentally applied to the regular body text instead of just the titles. To fix it, select your body paragraphs, go to the Home tab, and apply the 'Normal' style. Then update your Table of Contents.
How do I update the Table of Contents after adding new headings?
Go to the References tab, click Update Table, and choose 'Update entire table' to automatically pull in any newly formatted headings and correct the page numbers.
Can I change how the headings look without breaking the Table of Contents?
Yes. You can right-click any heading style in the Styles gallery, select Modify, and change the font, color, or size. The Table of Contents relies on the structural outline level, not the visual formatting, so it will continue to work perfectly.
Why are my custom styles not appearing in the TOC options?
By default, custom styles have an outline level of 'Body Text'. You must modify the paragraph settings of your custom style to assign it a specific outline level (e.g., Level 1 or Level 2) so the software recognizes it as a heading for the Table of Contents.




