Content · Web Development · HTML

HTML Accessible Page Title and Logical Headings

Accessible Page Title and Logical Headings: Try moving through the elements with a keyboard. The labels and relationships matter even when no extra styling has been added. Includes a practical HTML example and an explanation.

1 views Published Oct 19, 2026 Updated Oct 19, 2026 Admin

Not everyone uses a mouse to explore a website. Good HTML must also make sense through a keyboard or screen reader.

What You Need to Know


The browser tab title and the visible page heading have different jobs. A clear title helps someone recognize a tab or search result; a logical heading structure helps them understand the content after opening it.

Try the Example


Take a look at the example. We’ll explain the important lines right below it.

<main>
    <h1>School newspaper</h1>
    <section aria-labelledby="science-title">
        <h2 id="science-title">Science</h2>
        <h3>New robotics club</h3>
        <p>Students meet each Thursday.</p>
    </section>
</main>

Let’s Read the Code


  • <main>: The main element marks the primary page content.
  • <h1>: A top-level heading explains what the page is about.
  • aria-labelledby: Aria-labelledby uses the text of another element as the accessible name.
  • id: An id uniquely identifies an element on this page.

Read the named elements and attributes together. They explain how the browser connects this feature to the rest of the page.

What Happens in the Browser?


Try this with Tab and Shift+Tab. If you can, inspect the accessibility tree too; appearance alone does not tell the whole story.

What does assistive technology receive? The example includes aria-labelledby. These relationships can explain names, states, or descriptions when used correctly. They do not automatically move focus, listen for clicks, or create keyboard handling.

Your Turn


Use Tab and Shift+Tab to visit the controls, then read their labels aloud. Is the purpose of each one clear?

Common Beginner Mistakes


  • Judging the page only by how it looks, without checking its meaning and keyboard behavior.
  • ARIA changes what assistive technology is told; it does not automatically add keyboard controls, visual styling, or JavaScript behavior.

Key Takeaways


  • The browser tab title and the visible page heading have different jobs.
  • <main>: The main element marks the primary page content.
  • A meaningful HTML element is usually a stronger starting point than adding an ARIA role to a generic div. Also check what happens using only the keyboard.
Share this resourceSend this page to someone who may find it useful.