Why this wireframe works | Top-of-article table of contents
The structure is clear before reading
With the headings listed, readers can tell what the article covers and whether what they want is there before they start. If the section they need is missing, they can leave before reading.
Always visible, nothing to learn
There is nothing to open or close, so the items can be pressed as soon as the page opens. First-time visitors are never unsure how to use it.
Never out of step with the headings
The contents are built from the body headings, so editing a heading never leaves an old item behind. Search engines and AI also see the structure as a list of headings.
Common mistakes | Top-of-article table of contents
Listing h3 too, so the contents grow long
Adding subheadings pushes the list past 20 items and the contents fill the screen. List h2 only and leave finer headings to the body.
Headings hidden under a sticky header after the jump
After moving from the contents, the heading slides under the fixed header and readers cannot tell where they are. Give headings scroll-margin-top equal to the header height.
Contents made as an image or typed by hand
When a heading changes, the contents do not, and items lead to the wrong place. Generate the contents automatically from the body headings.
Items worded differently from the headings
When the contents use shortened wording that does not match the heading, readers have to check whether they landed in the right place. Use the heading text as it is.
FAQ | Top-of-article table of contents
How many items can the contents have?
About five to eight. Keep it within one screen on desktop and two on mobile. Beyond that, drop h3 or switch to the collapsible type (TOC-002).
Does the contents need a heading that says Contents?
Even when it is visibly a table of contents, the nav needs a name for screen readers. If you do not want a visible heading, add aria-label with the name Contents.
Should the table of contents at the top start expanded?
This pattern assumes the table of contents is always visible, so place it expanded. If there are so many entries that the article gets pushed down, limit it to h2 headings or consider the collapsible pattern that starts closed.













