All 14 Table of Contents sections

See every section

Getting around

Updated Table of Contents 1.8.1Tested with WordPress 7.1

Enable smooth scrolling is the smooth scroll. With it off the page jumps straight there instead. Either way keyboard focus moves to the heading, which is what makes the jump work for somebody not using a mouse.

A heading inside a closed section is opened before the jump: a Details block, a panel of WordPress's Accordion block, or a WooCommerce product's Description tab while another tab is showing. A link that arrives at such a heading opens it too, and nothing is closed again afterwards. Another plugin's accordion that hides its panels its own way cannot be opened from outside, so its entry scrolls to the closed accordion, where the reader can open it.

Highlight the current section highlights the entry for whichever section the reader is in. Before the first heading nothing is marked, because saying the reader is in the first section while they are still in the introduction is untrue.

Scroll offset (px) and your sticky header are the fix for the single most common complaint about every table of contents plugin: you jump to a section and the heading is hidden under a fixed header. Name the header's CSS selector — .site-header, #masthead — and its height is measured on the day rather than guessed. Your admin bar is measured too, and only for the people who have one. Both apply whether smooth scrolling is on or off.

You may not need either. A jump also allows for anything the page has already told the browser is fixed at the top (many themes do this for their own sticky header), for our Free Shipping Bar when it is pinned to the top, and for our cookie banner while it is open there.

Show a copy link on each entry puts a small button on the row being pointed at, for sharing one section of a long article. On a touch screen, where nothing can be pointed at, it is always shown. A copied link says so in a short message at the foot of the screen, which screen readers read out too. If the browser will not copy, the link is offered in a box, selected and ready to copy by hand.

Still stuck? Ask the developers who wrote it. We aim to reply within one business day.