Headings and titles

Use descriptive headings and titles because they help a user navigate their browser and the page. It's easier to jump between pages and sections of a page if the headings and titles are unique.

Formatting a heading or title

  • Use sentence case for headings and titles. For more information, see Capitalization in titles and headings.
  • When using an abbreviation in a heading or title, spell out the abbreviation in the first paragraph that follows the heading or title. For more information, see Abbreviations.
  • Avoid using code items in headings when possible. If you must mention a code item in a heading, add a descriptive noun to the item in code font. For more information, see keywords.
  • Tag headings using heading elements. In HTML: <h1>, <h2>, and so on. In Markdown: #, ##, and so on.
  • Use API levels for Android versions.
  • To change the visual formatting of a heading, use CSS rather than using a heading level that doesn't fit the hierarchy. Don't make up your own formatting for headings.
  • Use a heading hierarchy and take the following items under consideration:
    • Use a level-1 heading for the page title or main content heading. In some publishing systems, a level-1 heading might be generated automatically based on a page title that you supply.
    • Don't skip levels of the heading hierarchy. For example, put an <h3> only under an <h2>.

      Not recommended:

      # Transferring data sets
      This article provides a high-level overview of ways to transfer your data to GCP.
      ### Estimating costs
      

      Recommended:

      # Transferring data sets
      This article provides a high-level overview of ways to transfer your data to GCP.
      ## Estimating costs
      
    • Don't use empty headings or headings with no associated content.

      Not recommended:

      ## Migrating VMs to Compute Engine
      ### Designing the migration
      

      Recommended:

      ## Migrating VMs to Compute Engine
      Migration is not just a single step. The following sections describe the recommended steps.
      ### Designing the migration
      

Referring to subsections

In a section of the page that summarizes the following subheadings—for example, an H2 section that discusses the following H3 sections—use the phrase in the following sections to connect the headings together. Don't use the phrases in this section or in these sections because these phrases are too ambiguous.