How to Add Table of Contents in WordPress Pages and Posts

Have you ever found it difficult to locate information in a long article? Want to improve the reading experience for your visitors? A Table of Contents is the perfect solution for helping users navigate easily and enjoy a smooth reading experience.

WPTinker 9 Min Read

Table of Contents acts as a helpful guide, giving readers a clear roadmap of what’s ahead. It lets them jump easily to the sections that interest them most. Creating one in WordPress is simpler than you think, and we will show beginner-friendly methods to do it.

Why Should We Add a Table of Contents in WordPress Pages and Posts?

A Table of Contents (TOC) enhances the user experience by helping readers navigate directly to the content they’re interested in. Instead of scrolling or skimming, they can easily jump to specific sections. This makes your content more accessible and engaging.

In addition to improving UX, a Table of Contents boosts your SEO efforts. It gives you a chance to include relevant keywords in a natural way. These keywords are crucial for ranking higher on search engines.

A Table of Contents can also improve your chances of appearing in a featured snippet on Google. Lists like TOCs often show up because they clearly present answers to user queries. This increases the visibility of your content.

In WordPress, you can easily add a Table of Contents to your posts or pages without coding by using a plugin or built-in features in some themes.

How to Add Table of Contents in Foxiz Theme

You’re probably already familiar with the Foxiz Theme if you manage a news or blog website. If you’re new and looking to explore it, feel free to check it out here.

Foxiz comes with a built-in option to create a Table of Contents for your posts and pages. This feature is simple to use and doesn’t require additional plugins.

Table of Contents feature allows you to insert a table of contents into your posts, pages, or custom posts. Morever, it is generated based on the heading tags in your content and the settings you’ve configured. This allows the TOC to reflect the structure of your article, automatically updating as you add or modify headings in your post.

Create Table of Contents Using Theme Options

To enable the Table of Contents, navigate to Theme Options > Table of Contents.

You can input the text “post” into the “Support Post Types” option if you want it to work with posts. For example, “post, page, podcast.” Leave it blank to disable and input “all” to support all post types.

This flexibility allows you to control where the Table of Contents appears, ensuring it’s applied only to the content types that matter most for your site.

You can choose to turn on or turn off the heading support for the Table of Contents. When enabled, the TOC will be generated based on the heading tags (H1, H2, H3, etc.) in your content. If you turn off the heading support, the TOC will not include any headings, providing more control over what content is displayed in that.

You can customize the Table of Contents layout in Foxiz to fit your needs. Choose between column or “show number list” to organize headings clearly. This makes navigation easier and improves the reading experience.

Foxiz follows the principle of flexibility and user control, allowing you to enable or disable features as needed.

Specifically, you can choose to show or hide the Table of Contents on individual posts or pages directly from the Block Editor. This gives you the freedom to decide where it’s most useful, without affecting the entire site.

Control Table of Content Position Manually

In addition to the features mentioned above, Foxiz also gives you a flexible setting to control the Table of Contents placement. If you want more control, you can manually insert the TOC exactly where you want by adding a simple shortcode or string directly into your post content.

You only need to add the shortcode to your post or page within the Block Editor.

Once added, the Table of Contents will automatically appear at that exact location, giving your readers a clear and easy way to navigate through your content. This helps improve the user experience and keeps your posts well-organized.

So, we’ve just explored the Table of Contents feature in the Foxiz Theme. What we’ve covered is just an overview to get you started. Give Foxiz a try, explore its full potential, and feel free to come back and share your experience with us.

Adding Table of Contents With Plugins

If you’re using your own custom theme, you might not have a built-in Table of Contents feature. In that case, the easiest solution is to use a plugin. It’s a simple way to add this functionality without any coding, and you can set it up in just a few clicks.

Many WordPress SEO plugins come with a built-in Table of Contents feature. But if you prefer a dedicated TOC plugin, here are five great options to consider.

Easy Table of Contents

Easy Table of Contents is a popular WordPress plugin that lets you add a TOC without any coding. Simply adjust the settings, and it will automatically display on your posts and pages.

Pros:

  • Automatically generates a table of contents by detecting heading tags
  • Allows optional auto-insertion of the table of contents based on the selected post types
  • Offers simple, user-friendly settings to control where the table of contents appears
  • Includes bullet formats, hierarchy display, and color themes
  • Compatible with popular page builders and editors
  • Supports the Rank Math plugin and <!–nextpage–> the tag
  • Developer-friendly with many action hooks and filters available
  • Advanced features, including smooth scrolling, widget support, and selective visibility

Cons:

  • Enabling features like sticky TOC may lead to slower page load times
  • Some features are only available in the pro version, like host, tech support, etc.

Table of Contents Plus

Table of Contents Plus is ideal for complex WordPress sites with multi-page posts. Inspired by Wikipedia’s format, it allows users to create and display a TOC in the sidebar. Best of all, all its features are available for free.

Pros:

  • Appears before the first heading by default, allowing for lead-in content
  • Automatically generates a context-specific index, table of contents for lengthy pages
  • Uses a unique numbering scheme that remains consistent across different themes
  • Excludes specific heading levels and disabling the included CSS file
  • Includes an administration options panel for customizing display position
  • Can output a sitemap listing pages and/or categories across the entire site
  • Shortcodes available for generating sitemaps of pages, categories, and posts
  • Customizable attributes for sitemaps, such as heading levels, labels, and exclusions
  • Allows the table of contents to be included in the sidebar via a widget
  • Supports custom post types, with auto-insertion when the_content() is used

Cons:

  • There are compatibility issues with cache plugins and multilingual sites
  • The plugin lacks timely support, causing frustration for users

Conclusion

Adding a Table of Contents (TOC) to your WordPress posts and pages is an easy way to enhance the user experience and improve SEO. It helps readers quickly navigate long content and find the information they’re interested in. Whether you choose to use a plugin or the built-in theme options, a TOC can significantly improve your site’s structure.

We hope it helps improve your website’s usability and visibility. Have a nice day!

Share This Article
Leave a comment