Andrew's Digital Garden

HTML Content Categories

HTML elements are a member of one or more content categories. These categories group elements with common characteristics. Categories have a lot of overlap, and there's subset categories also.

Each category dictates acceptable descendants. e.g. p can only contain phrasing content, but div can contain flow content

  • Metadata content: metadata - head, title, link, etc
  • Flow content: a broad category that contains many other categories
    • Sectioning content: creates sections - article, aside, nav
    • Heading content: defines the title of a section - h1-h6
    • Phrasing content: text and markup
    • Embedded content: imports another resource
    • Interactive content: things designed for user interaction
    • Form-associated content

There's a few more, but these are the most common, but these are the 'main' ones

MDN often puts this in the technical summary as 'Content categories' and 'Permitted content'

https://developer.mozilla.org/en-US/docs/Web/HTML/Guides/Content_categories

[[html]]

HTML Content Categories