STR-001 Give every page a title that says what it is for, and change it with every view
- Level
- Rule
- Verdict
- Requirement
- Area
- Page structure
- Status
- proposed, version 1.0.1
Rule
Give every page a title, in the title element, that says what the page holds or is for. In a single page app, set a new title on every route change, so the title names the view now shown, not only the app.
Examples
Live examples built with Justified's components. Try them with the mouse, the keyboard or a screen reader.
Do: Each view sets its own title
fernhill.example/invoices
Invoices
Ready.
History, newest last:
- Settings – Fernhill
- Customers – Fernhill
- Invoices – Fernhill
Don't: One title on every view
fernhill.example/invoices
Invoices
Ready.
History, newest last:
- Fernhill
- Fernhill
- Fernhill
Don't: A placeholder leaks into the title
fernhill.example/invoices
Invoices
Ready.
History, newest last:
- Settings – Fernhill
- Customers – Fernhill
- Invoices – Fernhill
Don't: A personal detail in the title
fernhill.example/
Dashboard
Ready.
History, newest last:
- anna.berg@example.com – Customers
- anna.berg@example.com – Invoices
- anna.berg@example.com – Dashboard
Why
The title is what a browser tab, a bookmark and the history list show, and it is the first thing a screen reader says when a page opens. A person with ten tabs open finds the right one by its title. A screen reader user learns from it, before anything else, whether they have landed where they meant to. A title that says "React App" on every page tells them nothing, and one that never changes in a single page app gives no sign that the view has changed at all.
This is a requirement. WCAG 2.2, 2.4.2 Page Titled asks that pages have titles that describe their topic or purpose. In HTML the title is the title element in head (H25), and the Working Group's technique for a descriptive title asks that it names the subject and makes sense on its own (G88). The criterion's text does not mention single page apps. A route at its own address is its own web page, and the Working Group lists as a failure a title that a template repeats on every page, so the pages cannot be told apart by it (F25). For views that script swaps at one address, it also advises that the title change to match the current view (Understanding 2.4.2). The criterion does not ask for a fixed format or, beyond that, for titles that are unique. The format under Do is our own choice.
Do
- In the bookkeeping app Fernhill, the view at
/invoiceshas the title "Invoices – Fernhill", and the view at/invoices/2026-114has "Invoice 2026-114 – Fernhill". Each route sets its own. - In the Next.js App Router, export
metadataorgenerateMetadatafrom eachpage.tsx, and settitle.templateto"%s – Fernhill"in the root layout so every page gets the same ending. - In React 19, render
<title>inside the route's component; React moves it intohead. In React Router framework mode, use the route'smetaexport. In TanStack Router, use the route'sheadoption. With any other router, setdocument.titlewhen the route changes. - Replace the starter title before the first release. Vite's
index.htmlandcreate-next-appboth ship one that names the tool, not the product. - Our own choice: put the part that names the view first and the product name last, so tabs and screen reader announcements start with the words that differ.
- Our own choice: keep titles unique inside the product. Two views with the same title, such as two lists both called "Overview", get the words that tell them apart.
- Our own choice: make the title and the view's
h1say the same thing, as far as the product name. Theh1is STR-003. - Our own choice: when a form is shown again with problems, start the title with "Error: ", as in "Error: New invoice – Fernhill", so a screen reader user hears it first. Where focus goes is still FRM-011.
- Our own choice: keep personal details of the person using the app out of the title, such as their email address, phone number or account balance. Titles travel further than the page: into history, shared screens and reports. The name of a record they work on, such as an invoice number, is fine.
- Our own advice: while a view loads its data, show a sensible title at once, such as "Invoice – Fernhill", and make it specific when the data arrives.
- Our own advice: let a link's text and the title of the page it opens say the same thing, so people can tell they arrived where they meant to. Link text itself is TXT-003.
Don't
- Ship with "Vite + React + TS" or "Create Next App" as the title of every page.
- Set the title once in the root layout, so
/invoices,/customersand/settingsall read "Fernhill". - Let a template placeholder leak into the title before data arrives, so the tab reads "undefined – Fernhill" or "{invoice.number} – Fernhill".
- Put the signed-in person's email address in the title, as in "anna.berg@example.com – Dashboard".
- Write a title that repeats the product's tagline on every page, so it describes the product and never the view.
Exceptions
- Dialogs and sheets. A dialog or sheet that opens over a view does not need its own title. It has no route of its own, and its name comes from its heading.
- Tabs inside a view. Tabs that switch content inside one view keep the view's title. A tab that has its own route and its own heading is a view, and gets its own title.
- Not covered here. Whether focus moves or anything is announced after a route change is a separate question this rule does not decide.
- Neighbouring rules. The page's language, which changes along with the title when the interface switches language in place, is STR-006.
Verdict
Requirement. Only the judges decide; the expert witnesses are shown but do not vote. How verdicts work
| Source | Role | Stance | Page |
|---|---|---|---|
| WCAG 2.2 | Law | Requires | 2.4.2 Page Titled |
| Material Design | Judge | No position | |
| Apple Human Interface Guidelines | Judge | Supports | VoiceOver |
| Carbon Design System | Judge | No position | |
| GOV.UK Design System | Expert witness | Supports | Writing for user interfaces Error summary |
| Nielsen Norman Group | Expert witness | Supports | Navigation: You Are Here, by Susan Farrell Microcontent: How to Write Headlines, Page Titles, and Subject Lines, by Hoa Loranger, Jakob Nielsen |
Each stance links to the page it rests on, read on the date in the source register. This page never repeats what a source says; read the source itself.
History
- Version 1.0.1, : Points to STR-006 for the page language when the interface switches language.
- Version 1.0.0, : First version.
Last checked against the other rules for conflicts on .
More in Page structure: 7 rules and 1 guideline · All rules
Justified is an independent project. It is not affiliated with, sponsored or endorsed by the organisations whose guidance it cites. Read the full statement.
Apple is a trademark of Apple Inc., registered in the U.S. and other countries and regions.