Section Headings

On this page, you’ll learn:

  • How to mark up section headings with AsciiDoc.

Heading syntax and levels

Sections partition a page into a content hierarchy. In AsciiDoc, sections are defined using section titles.

Example 1. Section title syntax
== Level 1 Section Title

=== Level 2 Section Title

==== Level 3 Section Title

===== Level 4 Section Title

====== Level 5 Section Title

== Another Level 1 Section Title

When a page is converted to HTML, each section title becomes a heading element where the heading level matches the number of equals signs. For example, a level 1 section (==) maps to an <h2> HTML tag.

Section headings must be defined using the Atx-style (single line) that begins with one or more equals signs.

Antora does not recognize the legacy Setext-style (i.e., underlined) heading syntax once supported in AsciiDoc, nor does it recognize Asciidoctor’s Markdown-style heading syntax. If you don’t use the Atx-style syntax, xrefs in the page will not be resolved and other features of AsciiDoc will not be available.
AsciiDoc and Asciidoctor resources