My Table of Contents is showing wrong or unrelated headings
When this happens, the widget is usually scanning too much of the page (or the wrong container).
Steps
Open your Table of Contents widget.
Go to Content β Data Source.
Keep Auto-detect selected.
In Content Selector, enter the wrapper that contains only your article body (example:
article,#main-content,.blog-post-body).In Headings, set exactly which heading tags should appear (example:
h2, h3).Save and preview again.

