--- url: "https://www.w3.org/WAI/WCAG22/Techniques/html/H42" titulek: "H42: Using h1-h6 to identify headings | WAI | W3C" h1: "Technique H42:Using h1-h6 to identify headings" popis: "" jazyk: "en" kanonicka: "" drobecky: [] zdroj: "live" wayback_snapshot: "" stazeno: "2026-09-14 04:42:52" znaku: 4270 slov: 668 kodovani: "utf-8" sha256: "17de4fcb7e101c9c8b8874ffaadb26c611dc40567cf1748c136ff2e9cc8b137d" --- # Technique H42:Using h1-h6 to identify headings ## About this Technique This technique relates to [1.3.1 Info and Relationships](https://www.w3.org/WAI/WCAG22/Understanding/info-and-relationships) (**Sufficient** when used for making information and relationships conveyed through presentation programmatically determinable). This technique applies to HTML. Techniques are examples of ways to meet Web Content Accessibility Guidelines (WCAG). They are **not required** to meet WCAG. Content can satisfy the normative requirements of WCAG even if it does not use any of the documented techniques. See [About WCAG Techniques](https://www.w3.org/WAI/WCAG22/Techniques/about). ## Description The objective of this technique is to use HTML heading markup to provide semantic code for headings in the content. Heading markup will allow assistive technologies to present the heading status of text to a user. A screen reader can recognize the code and announce the text as a heading with its level, beep or provide some other auditory indicator. Screen readers are also able to navigate heading markup which can be an effective way for screen reader users to more quickly find the content of interest. Assistive technologies that alter the authored visual display will also be able to provide an appropriate alternate visual display for headings that can be identified by heading markup. ## Examples ### Example 1: Hierarchical Heading Organization In the following example, headings are used in a hierarchical layout with `h3` as a subsection of `h2`, which is a subsection of `h1`. ```

Plant Foods that Humans Eat

There are an abundant number of plants that humans eat ...

Fruit

A fruit is a structure of a plant that contains its seeds ...

Apple

The apple is the pomaceous fruit of the apple tree ...

Orange

The orange is a hybrid of ancient cultivated origin ...

Banana

Banana is the common name for herbaceous plants ...

Vegetables

A vegetable is an edible plant or part of a plant other than a sweet fruit ...

Broccoli

Broccoli is a plant of the mustard/cabbage family ...

Brussels sprouts

The Brussels sprout of the Brassicaceae family, is a Cultivar group of wild cabbage ...

Green beans

Green beans have been bred for the fleshiness, flavor, or sweetness of their pods ...

``` ### Example 2: Headings in a three-column layout In this example, the main content of the page is in the middle column of a three-column page. The title of the main content matches the title of the page, and is marked as `h1`, even though it is not the first thing on the page. The content in the first and third columns is less important, and marked with `h2`. Note It is important to note that the example code below is not intended to prescribe what level of heading should be used for a particular section of the web page. In the example, the layout could be presented with the first heading in each column at the same logical level (such as an `h1`), or as found in the example, where the logical level reflects its importance in relation to the main content. ``` Stock Market Up Today

Stock Market up today

``` ## Related Resources *No endorsement implied.* - [HTML - the `h1`, `h2`, `h3`, `h4`, `h5`, and `h6` elements](https://html.spec.whatwg.org/multipage/sections.html#the-h1,-h2,-h3,-h4,-h5,-and-h6-elements) . - [MDN `

` - `

`: The HTML Section Heading elements](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/Heading_Elements) . - [Nomensa: How to structure headings for web accessibility](https://www.nomensa.com/blog/how-structure-headings-web-accessibility) . - [WebAIM: Semantic Structure: Regions, Headings, and Lists](https://webaim.org/techniques/semanticstructure/) . ## Tests ### Procedure 1. Check that heading markup is used when content is a heading and the heading markup indicates the appropriate heading level for the content. 2. Check that heading markup is not used when content is not a heading. ### Expected Results - Checks #1 and #2 are true. Back to Top