Previous task
Text markup with HTML2/10
Back to the list of tasks
  1. 1. Paragraphs
  2. 2. Headings and subheadings
  3. 3. Unordered list
  4. 4. Ordered list
  5. 5. Multilevel list
  6. 6. Description List
  7. 7. Strong and b tags
  8. 8. Em and i tags
  9. 9. Line breaks and separators
  10. 10. Preformatted text
Nest task
  • Courses
  • Sign up
  • Log in

Loading...
It will be ready in a few seconds.

  • Theory
  • Theory

Headings and subheadings

Headings are commonly used to create structure in large texts.

The HTML language provides a whole family of tags for headings, from <h1> to <h6>. The <h1> tag indicates the most important heading (the top-level heading), and the <h6> tag indicates the lowest-level subheading.

In practice, it is rare to find texts with subheadings below the third level. Therefore, the most frequently used heading tags are: <h1>, <h2> and <h3>.

It is worth noting that search engines give special importance to headings, so you need to learn how to use them correctly.

  • index.html
HTML
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>Headings and subheadings</title> </head> <body> 1 Headings <p>Headings are one of the most important tools for structuring text.</p> 1.1 Usage guidelines <p>Here are some guidelines for using headings in an HTML page.</p> 1.1.1 Use of h1 <p>It is not recommended that a single page contain multiple top-level headings.</p> 1.1.2 Use of h2-h6 <p>When using subheadings, it is not recommended to skip heading levels, i.e. h1 should be followed by h2 and only then h3.</p> </body> </html>

The code has changed, click "Update" or enable autorun.

You have moved to another page

Click inside the mini-browser to highlight this window.

100%
GoalsCompleted
0
    1. Wrap the text "1 Headings" in the <h1> tag.
    2. Wrap the text "1.1 Usage guidelines" in the <h2> tag.
    3. Wrap the text "1.1.1 Use of h1" and the text "1.1.2 Use of h2-h6" in the <h3> tags.

    © 2023-2024, codehero.pro