Techniques for WCAG 2.0

On this page:

-

# H25: Providing a title using the title element

## Applicability

HTML and XHTML

This technique relates to:

- Success Criterion 2.4.2 (Page Titled)
  - How to Meet 2.4.2 (Page Titled)
  - Understanding Success Criterion 2.4.2 (Page Titled)

## Description

All HTML and XHTML documents, including those in individual frames in a frameset, have a `title` element in the `head` section that defines in a simple phrase the purpose of the document. This helps users to orient themselves within the site quickly without having to search for orientation information in the body of the page.

Note that the (mandatory) `title` element, which only appears once in a document, is different from the `title` attribute, which may be applied to almost every HTML and XHTML element.

## Examples

### Example 1

This example defines a document's title.

Example Code:

    <html xmlns="http://www.w3.org/1999/xhtml">
       <head>
          <title>The World Wide Web Consortium</title>
       </head>
       <body>
          ...
       </body>
    </html>

## Resources

Resources are for information purposes only, no endorsement implied.

- HTML 4.01 TITLE element

## Related Techniques

- G88: Providing descriptive titles for Web pages
- G127: Identifying a Web page's relationship to a larger collection of Web pages

## Tests

### Procedure

1. Examine the source code of the HTML or XHTML document and check that a non-empty `title` element appears in the `head` section.

2. Check that the `title` element describes the document.

### Expected Results

- Checks 1 and 2 are true.

- Top
- Contents
- Intro
- Previous: Technique H24
- Next: Technique H27