|$ curl https://forge-ai.dev/api/markdown?path=docs/html/tags
$cat docs/complete-html-tag-reference.md
updated Today·60 min read·published

Complete HTML Tag Reference

HTMLTagsReferenceAll Levels🎯Free Tools
Introduction

A complete HTML tag encyclopedia matters because the language is the contract between authors, browsers, assistive technology, search engines, and AI agents. Every tag encodes meaning: content models constrain nesting, attributes configure behavior, and accessibility mappings decide how screen readers announce the page. Guessing tags from muscle memory leaves gaps; a systematic reference closes them.

For humans, this page is a field guide: pick the right element for the job, avoid deprecated markup, and wire forms, media, and landmarks correctly. For AI agents crawling ForgeLearn via ?format=md or Accept: text/markdown, it is a structured inventory of every HTML5 element with purpose, model, key attributes, and a11y notes — so generated markup stays semantic rather than div-soup.

HTML5 is a living standard (WHATWG). This encyclopedia covers the current element set: document metadata, sectioning, text, embedded media, tabular data, forms, interactive widgets, web-component primitives, edit markers, and tags you must never ship. Pair it with the deeper topic pages linked throughout and the Master HTML path when you are ready to practice end-to-end.

info

Prefer the most specific native element before reaching for ARIA roles on generic containers. Correct tags give you keyboard behavior, semantics, and SEO for free.
How to Read Each Entry

Category tables use five columns. Learn the vocabulary once, then scan any row quickly when you need a decision.

ColumnMeaning
TagElement name. Void elements are noted in Purpose when relevant.
ModelPrimary content model or category (metadata, flow, phrasing, sectioning, heading, embedded, interactive, none/void).
PurposeWhat the element represents and when it is the right choice.
Key attributesThe attributes you will use most often beyond globals.
AccessibilityDefault role / a11y expectations and common pitfalls.
📝

note

Content models are not CSS display values. A phrasing element can be styled as a block; validity is about nesting rules in the HTML parser and the outline of meaning — not how it looks.
Document Root & Metadata

Every page starts with a doctype and a root html element containing head (metadata) and body (visible content). Metadata elements configure charset, viewport, titles, stylesheets, scripts, and machine-readable description. Get this layer wrong and SEO, performance, and encoding fail before the first heading renders.

TagModelPurposeKey attributesAccessibility
htmlRootDocument root; wraps head + bodylang, dirAlways set lang for screen readers & hyphenation
headMetadataContainer for metadata childrenNot exposed in a11y tree as content
bodyFlowVisible page content rootonload (prefer JS listeners)Landmark document; avoid redundant roles
titleMetadata / textDocument title (tab, SERP, bookmarks)First thing SRs announce; keep unique & clear
baseMetadata / voidBase URL for relative linkshref, targetRare; can surprise link resolution
metaMetadata / voidCharset, viewport, description, OG, CSPcharset, name, content, property, http-equivIndirect a11y via viewport & language
linkMetadata / voidStylesheets, icons, preconnect, preloadrel, href, as, media, crossoriginPrefers-color-scheme sheets help users
styleMetadataEmbedded CSSmedia, nonce, blockingDo not hide focus outlines permanently
scriptMetadata / phrasingJS modules or classic scriptssrc, type, defer, async, nomoduleKeep progressive enhancement; test without JS
noscriptMetadata / flowFallback when scripting is offProvide usable alternative content
document-shell.html
HTML
1<!DOCTYPE html>
2<html lang="en">
3<head>
4 <meta charset="utf-8" />
5 <meta name="viewport" content="width=device-width, initial-scale=1" />
6 <title>ForgeLearn — HTML Tag Encyclopedia</title>
7 <meta name="description" content="Complete HTML5 tag reference." />
8 <link rel="stylesheet" href="/styles.css" />
9 <link rel="preconnect" href="https://fonts.googleapis.com" />
10 <script type="module" src="/app.js" defer></script>
11</head>
12<body>
13 <!-- Page content -->
14</body>
15</html>

best practice

Put charset within the first 1024 bytes. Always include a viewport meta for mobile. Prefer type="module" with defer semantics over blocking classic scripts in head.
Document Sections & Headings

Sectioning and heading elements define the page outline: landmarks for assistive tech, topical boundaries for readers, and SEO signals for crawlers. One main, clear nav, and a logical heading hierarchy beat decorative wrappers every time.

TagModelPurposeKey attributesAccessibility
headerFlow / sectioning-ishIntroductory content for page or sectionbanner landmark when child of body
navSectioningMajor navigation linksaria-label when multiple navsnavigation landmark; label duplicates
mainFlowDominant unique content of the pageExactly one visible main; main landmark
articleSectioningSelf-contained composition (post, card)article role; nest carefully
sectionSectioningThematic grouping with a headingregion if labeled; else generic
asideSectioningTangentially related content (sidebar)complementary landmark
footerFlowFooter for page or sectioncontentinfo when child of body
searchFlowSite or page search landmarksearch landmark (prefer over role="search")
addressFlowContact info for nearest article/bodyNot for postal-only addresses without contact
h1–h6HeadingSection headings by rankheading roles; do not skip ranks for style
hgroupHeadingGroups heading + related h* subtitlesOnly the highest-rank heading is exposed as heading

Semantic page shell — the landmark pattern you should memorize:

semantic-shell.html
HTML
1<header>
2 <a href="/">ForgeLearn</a>
3 <nav aria-label="Primary">
4 <a href="/docs">Docs</a>
5 <a href="/docs/html">HTML</a>
6 </nav>
7 <search>
8 <form role="search" action="/search">
9 <label for="q">Search</label>
10 <input id="q" name="q" type="search" />
11 </form>
12 </search>
13</header>
14<main>
15 <article>
16 <h1>Complete HTML Tag Reference</h1>
17 <section>
18 <h2>Document sections</h2>
19 <p>Landmarks and headings define the outline.</p>
20 </section>
21 </article>
22 <aside>
23 <h2>On this page</h2>
24 <nav aria-label="Page">…</nav>
25 </aside>
26</main>
27<footer>
28 <address>Contact: docs@forgelearn.dev</address>
29</footer>
preview

warning

Do not wrap every div in section. A section should introduce a new thematic topic — usually with its own heading. Empty decorative sections pollute the outline.
Text Content

Flow-level text containers structure paragraphs, lists, quotes, figures, and generic grouping. Choose semantic list and quote elements before inventing CSS-only patterns — screen readers and copy/paste behavior depend on them.

TagModelPurposeKey attributesAccessibility
pFlowParagraph of phrasing contentDefault paragraph; avoid nested interactive blocks
hrFlow / voidThematic break between topicsseparator role; not for pure decoration
preFlowPreformatted text (whitespace preserved)Pair with code for source samples
blockquoteFlowExtended quotation from another sourceciteNot for indentation styling alone
olFlowOrdered liststart, reversed, typelist / listitem mapping
ulFlowUnordered listlist / listitem mapping
menuFlowToolbar / context menu of commands (semantic ul-like)Often exposed like a list; prefer for action lists
liList item inside ol/ul/menuvalue (ol only)listitem
dlFlowDescription / association listterm/definition groups
dtTerm in a dlterm role
ddDescription / value for a dtdefinition role
figureFlowSelf-contained media/code with optional captionfigure role; caption associates
figcaptionCaption for figureNames the figure
divFlowGeneric flow container — no semanticsLast resort; add ARIA only when needed
🔥

pro tip

Use dl for name/value metadata (specs, glossaries, product details), not just dictionary words. Multiple dt/dd pairs in one list are valid.
Inline Text Semantics

Phrasing elements annotate meaning inside paragraphs and headings: emphasis, idiomatic voice, code, dates, bidirectional text, and hyperlinks. Prefer semantic tags over presentational spans so meaning survives themes and assistive technology.

TagModelPurposeKey attributesAccessibility
aPhrasing / interactiveHyperlink (or placeholder without href)href, target, rel, downloadlink role; never nest interactive content
emPhrasingStress emphasisOften italic; conveys emphasis to SRs
strongPhrasingStrong importanceNot for visual bold alone — use CSS/b when needed
smallPhrasingSide comments / fine printSemantic small print, not just font-size
sPhrasingContents no longer accuratePrefer del for document edits
citePhrasingTitle of a cited creative workNot for people names
qPhrasingInline quotation (browser adds quotes)citeUse blockquote for long quotes
dfnPhrasingDefining instance of a termtitleFirst definition in context
abbrPhrasingAbbreviation / acronymtitle (expansion)Provide expansion in text or title
ruby / rt / rpPhrasingRuby annotations (e.g. furigana)rp for fallback parentheses
dataPhrasingMachine-readable value alongside human textvalueHuman text remains primary
timePhrasingDate / time with machine valuedatetimeUse unambiguous datetime values
codePhrasingFragment of computer codeNest code inside pre for multi-line samples
varPhrasingVariable in math or programmingSemantic italic often
sampPhrasingSample program outputPair with kbd for CLI tutorials
kbdPhrasingUser keyboard / voice inputNest for key chords
sub / supPhrasingSubscript / superscriptUse for meaning (formulas), not layout
iPhrasingIdiomatic / alternate voice (taxonomic names, terms)Not for emphasis — use em
bPhrasingAttention offset without extra importanceNot strong importance — use strong
uPhrasingUnarticulated annotation (misspelling, proper names in Chinese)Avoid underline that looks like links
markPhrasingHighlighted / marked for referencemark role; search-result highlights
bdi / bdoPhrasingBidirectional isolate / overridedirCritical for mixed LTR/RTL user content
spanPhrasingGeneric phrasing hook — no semanticsStyling/hooks only
brPhrasing / voidLine break in poetry/addressesNot for spacing between blocks — use CSS
wbrPhrasing / voidOptional word-break opportunityHelps long URLs wrap without hyphenation
📝

note

i/b/u are not deprecated — they have semantic jobs distinct from em/strong. Use them when italic/bold/underline convey classification or attention without changing importance.
Images & Media

Embedded content brings pixels, vectors-as-raster, audio, video, maps, and nested browsing contexts into the document. Always provide text alternatives, dimensions for layout stability, and captions or tracks when media carries speech.

TagModelPurposeKey attributesAccessibility
imgEmbedded / voidImage resourcesrc, alt, srcset, sizes, width, height, loading, decodingMeaningful alt; empty alt for decorative
pictureEmbeddedArt direction / format negotiationContains source + imgalt lives on the inner img
sourceVoidMedia/picture candidatesrcset, sizes, media, type, srcNot independently focusable
mapFlowImage map definitionnamePrefer HTML links when possible
areaPhrasing / voidHotspot in an image mapshape, coords, href, altalt required when href present
audioEmbeddedSound playbacksrc, controls, autoplay, loop, muted, preloadProvide controls; avoid autoplay with sound
videoEmbeddedVideo playbacksrc, poster, controls, width, height, playsinlineCaptions via track; keyboard controls
trackVoidTimed text (captions, chapters, descriptions)kind, src, srclang, label, defaultkind="captions" for deaf/hard-of-hearing
embedEmbedded / voidExternal plugin/plugin-like contentsrc, type, width, heightPrefer iframe/object; sandbox carefully
objectEmbeddedExternal resource with fallback childrendata, type, nameFallback content inside object
iframeEmbeddedNested browsing contextsrc, title, sandbox, allow, loading, referrerpolicytitle required; tighten sandbox

Responsive picture with format fallbacks — see also /docs/html/picture:

picture-art-direction.html
HTML
1<figure>
2 <picture>
3 <source
4 type="image/avif"
5 srcset="/hero-800.avif 800w, /hero-1200.avif 1200w"
6 sizes="(max-width: 700px) 100vw, 700px"
7 />
8 <source
9 type="image/webp"
10 srcset="/hero-800.webp 800w, /hero-1200.webp 1200w"
11 sizes="(max-width: 700px) 100vw, 700px"
12 />
13 <img
14 src="/hero-800.jpg"
15 width="700"
16 height="394"
17 alt="Terminal-style documentation homepage"
18 loading="lazy"
19 decoding="async"
20 />
21 </picture>
22 <figcaption>Art direction + modern formats with JPEG fallback.</figcaption>
23</figure>
preview

warning

Never omit alt on content images. Missing alt causes screen readers to announce the filename. Decorative images use alt="" (empty), not a missing attribute.
Canvas, SVG & Math

Some embedded content is script-driven or XML-namespaced. Use these when HTML text and CSS cannot express the graphic — then add accessible fallbacks.

TagModelPurposeKey attributesAccessibility
canvasEmbeddedBitmap drawing surface (2D / WebGL)width, heightProvide fallback text; expose via ARIA / hit regions
svgEmbeddedInline scalable vector graphicsviewBox, role, aria-label / titleLabel decorative vs informative SVGs

Deep dives: /docs/html/canvas for the 2D API and animation, /docs/html/svg for shapes, paths, and accessible SVG patterns.

📝

note

MathML may appear via math in supporting browsers, or through libraries that render accessible math. Prefer MathML or well-labeled SVG/Canvas over screenshots of equations. HTML itself does not replace a dedicated math guide — treat formulas as content that needs text equivalents.
canvas-svg-brief.html
HTML
1<!-- Canvas: pixels under script control -->
2<canvas id="chart" width="320" height="180" role="img" aria-label="Bar chart of weekly visits">
3 Weekly visits: Mon 40, Tue 55, Wed 48.
4</canvas>
5
6<!-- SVG: resolution-independent, stylable DOM -->
7<svg viewBox="0 0 100 100" width="64" height="64" role="img" aria-labelledby="logo-title">
8 <title id="logo-title">ForgeLearn mark</title>
9 <circle cx="50" cy="50" r="45" fill="none" stroke="#00FF41" stroke-width="4" />
10 <path d="M30 65 L50 25 L70 65 Z" fill="#00FF41" />
11</svg>
Tabular Data

Tables express relationships between rows and columns — not page layout. Use captions, headers with scope, and proper sectioning elements so assistive tech can navigate by cell.

TagModelPurposeKey attributesAccessibility
tableFlowTabular data containertable role; never for layout
captionTable title (first child)Names the table
colgroupGroup of columns for stylingspanPresentational grouping
colVoidColumn within colgroupspan
theadHeader row grouprowgroup
tbodyBody row group(s)rowgroup
tfootFooter row group (totals)rowgroup
trTable rowrow
thHeader cellscope, colspan, rowspan, headers, abbrcolumnheader / rowheader
tdData cellcolspan, rowspan, headerscell; associate via headers if complex

best practice

Always include scope="col" or scope="row" on th cells. Complex tables may need headers/id associations — see /docs/html/tables.
Forms & Controls

Forms collect user input with native validation, labels, and submission semantics. Every control needs an accessible name — usually via label with matching for/id.

TagModelPurposeKey attributesAccessibility
formFlowInteractive submission containeraction, method, enctype, novalidate, autocompleteform role; group related fields
labelPhrasing / flowCaption for a controlforClickable name; never skip labels
inputPhrasing / void / interactiveTyped control (see type table)type, name, value, required, pattern, …Role depends on type
buttonPhrasing / interactiveClickable buttontype (submit|button|reset), disabled, nameDefault type is submit inside forms
selectPhrasing / interactiveOption pickername, multiple, size, requiredcombobox / listbox mapping
datalistPhrasingAutocomplete suggestions for inputsid (matched by list=)Suggestions only — still label the input
optgroupGroup of options in a selectlabel, disabledlabel required for the group
optionChoice in select/datalistvalue, selected, disabled, labeloption role
textareaPhrasing / interactiveMulti-line text entryname, rows, cols, maxlength, requiredtextbox multiline
outputPhrasingResult of a calculationfor, name, formstatus/output; update live carefully
progressPhrasingTask completion gaugevalue, maxprogressbar role
meterPhrasingScalar measurement within a known rangevalue, min, max, low, high, optimumNot for progress bars — use progress
fieldsetFlowGroup related controlsdisabled, name, formgroup; legend provides name
legendCaption for fieldsetFirst child of fieldset

input types — pick the right type for mobile keyboards, validation, and semantics:

typeUse forNotes
textSingle-line free textDefault; use autocomplete
searchSearch fieldsOften styled with clear control
email / url / telContact identifiersBuilt-in format hints + mobile keyboards
passwordSecretsObscured; autocomplete=current/new-password
number / rangeNumeric entry / slidermin, max, step
date / time / datetime-local / month / weekTemporal valuesNative pickers vary by browser
colorColor pickerValue as #rrggbb
fileFile uploadaccept, multiple, capture
checkbox / radioBoolean / exclusive choiceSame name for radio groups
hiddenNon-visible submitted dataNot for secrets in HTML source
submit / reset / button / imageForm actionsPrefer button element for rich content
accessible-form.html
HTML
1<form action="/subscribe" method="post" novalidate>
2 <fieldset>
3 <legend>Newsletter</legend>
4 <label for="email">Email</label>
5 <input id="email" name="email" type="email" required autocomplete="email" />
6
7 <label for="freq">Frequency</label>
8 <select id="freq" name="frequency" required>
9 <optgroup label="Common">
10 <option value="weekly">Weekly</option>
11 <option value="monthly">Monthly</option>
12 </optgroup>
13 <option value="daily">Daily</option>
14 </select>
15
16 <label for="topics">Topics</label>
17 <input id="topics" name="topics" list="topic-list" />
18 <datalist id="topic-list">
19 <option value="HTML"></option>
20 <option value="CSS"></option>
21 <option value="JavaScript"></option>
22 </datalist>
23
24 <label>
25 <input type="checkbox" name="tos" required />
26 I agree to the terms
27 </label>
28 </fieldset>
29
30 <button type="submit">Subscribe</button>
31 <progress id="upload" max="100" value="0" hidden>0%</progress>
32</form>
preview
Interactive Widgets

Native disclosure and dialog patterns reduce custom JavaScript and come with keyboard support. Prefer them before reinventing accordions and modals.

TagModelPurposeKey attributesAccessibility
detailsFlow / interactiveDisclosure widgetopen, name (exclusive accordion)group; summary is the button
summaryVisible label / toggle for detailsMust be first summary child
dialogFlowModal or non-modal dialogopen; showModal() / close()Focus trap in modal; Escape closes
🔥

pro tip

The global popover attribute (and popovertarget on buttons) creates top-layer UI without a full modal dialog — light dismiss, focus management, and no custom stacking hacks. See /docs/html/dialog-popover.
details-dialog.html
HTML
1<details name="faq">
2 <summary>What is a content model?</summary>
3 <p>A content model defines what child elements are valid inside a parent.</p>
4</details>
5<details name="faq">
6 <summary>When do I use dialog vs popover?</summary>
7 <p>Use dialog for focused tasks that need a backdrop; popover for menus and non-modal tips.</p>
8</details>
9
10<button type="button" id="open">Open dialog</button>
11<dialog id="confirm">
12 <form method="dialog">
13 <p>Reset your progress?</p>
14 <button value="cancel">Cancel</button>
15 <button value="ok">Confirm</button>
16 </form>
17</dialog>
18
19<script>
20 const d = document.getElementById("confirm");
21 document.getElementById("open").onclick = () => d.showModal();
22</script>
preview
Web Components Primitives

Custom elements extend HTML with author-defined tags. The platform primitives are template, slot, and the Custom Elements registry — covered in depth at /docs/html/web-components, /docs/html/template-slot, and /docs/html/custom-elements.

TagModelPurposeKey attributesAccessibility
templateMetadata / inertInert DOM fragment for cloningshadowrootmode (declarative shadow DOM)Not rendered until cloned/activated
slotPhrasing / flowProjection point in shadow treesnameLight DOM children keep their semantics

Custom element naming rules: names must include a hyphen (e.g. forge-card), must not be empty after the hyphen, and are case-insensitive ASCII. Autonomous elements extend HTMLElement; customized built-ins use is="…" where supported. Always define accessible names and keyboard behavior inside your component — the hyphenated tag alone does not grant a role.

template-slot.html
HTML
1<template id="card-tpl">
2 <style>
3 :host { display: block; border: 1px solid #222; padding: 12px; }
4 </style>
5 <h2><slot name="title">Untitled</slot></h2>
6 <div><slot></slot></div>
7</template>
8
9<!-- Valid custom element name: lowercase + hyphen -->
10<forge-card>
11 <span slot="title">Semantics first</span>
12 <p>Light DOM content projects through slots.</p>
13</forge-card>
Scripting & Document Edits

Scripting elements appear again here because they also live in the body; edit elements mark insertions and deletions for changelogs and reviews.

TagModelPurposeKey attributesAccessibility
scriptMetadata / phrasingExecute or load script; also JSON-LDsrc, type, defer, async, integrityEnsure critical UX works without JS
noscriptMetadata / flowFallback when scripts disabledMust still be usable content
templateMetadataClient-side fragment storeshadowrootmodeInert until used
delPhrasing / flowRemoved content in a document editcite, datetimedeletion; announce as removed when supported
insPhrasing / flowInserted content in a document editcite, datetimeinsertion
edits.html
HTML
1<p>
2 The living standard is maintained by
3 <del cite="/changelog/2024" datetime="2024-01-01">the W3C HTML WG</del>
4 <ins cite="/changelog/2024" datetime="2024-01-01">WHATWG</ins>.
5</p>
Obsolete — Do Not Use

These tags are obsolete or non-conforming. Browsers may still parse some for compatibility, but authors must not use them in new documents. Replace them with semantic HTML and CSS.

Obsolete tagUse instead
acronymabbr
appletembed / object / modern JS — never Java applets
basefontCSS font-family / font-size on root
bigCSS font-size / relative sizing
blinkCSS animation (respect prefers-reduced-motion)
centerCSS text-align / flexbox / grid
fontCSS color, font-family, font-size
frame / frameset / noframesiframe + CSS layout; never framesets
isindexform + input type="search"
keygenWeb Crypto / platform auth — not keygen
listing / plaintext / xmppre + code
marqueeCSS animation / carousel patterns with pause controls
nobrCSS white-space: nowrap
noembedFallback inside object / picture patterns
spacerCSS margin / gap / padding
strikes (inaccurate) or del (edits)
ttcode, kbd, samp, or CSS font-family: monospace

danger

Framesets break accessibility, bookmarking, and responsive design. If you encounter frameset in legacy apps, plan a migration to a single document with CSS grid and optional iframe embeds.
Global Attributes — Quick Reference

Global attributes apply to nearly every HTML element. Master these before memorizing niche per-element APIs.

AttributePurpose
accesskeyKeyboard shortcut hint (use sparingly; conflicts common)
autocapitalizeVirtual keyboard capitalization behavior
autofocusFocus on page load (one per document; careful with a11y)
classSpace-separated CSS / JS hooks
contenteditableMake element editable by the user
data-*Custom data attributes (dataset API)
dirText direction: ltr, rtl, auto
draggableHTML Drag and Drop participation
enterkeyhintVirtual keyboard Enter key label
hiddenHide from presentation (until removed / until-found)
idUnique document identifier (labels, fragments)
inertMake subtree non-interactive and a11y-inert
inputmodeVirtual keyboard type hint
isCustomized built-in element name
item*Microdata: itemscope, itemtype, itemprop, itemid, itemref
langLanguage of the element's contents
nonceCSP nonce for inline script/style
part / exportpartsShadow DOM styling hooks
popoverDeclare a popover element (auto | manual)
slotAssign light DOM to a named slot
spellcheckHint for spell checking
styleInline CSS (prefer classes for reuse)
tabindex0 = in tab order; -1 = programmatically focusable
titleAdvisory tooltip text (not a label substitute)
translateWhether translators should translate content
writingsuggestionsBrowser writing-suggestions hint
aria-*ARIA attributes for roles/states when native HTML is insufficient
roleARIA role override — use only when no native element fits

info

Prefer native semantics over role + tabindex recreations. A real button already handles Enter/Space, focus, and form participation.
Content Models Cheatsheet

When the parser or validator complains about nesting, match the child's category to the parent's allowed content model.

ModelWhat it meansTypical members
MetadataDocument-level info & resourcesbase, link, meta, noscript, script, style, template, title
FlowMost body contentp, div, section, lists, tables, forms, …
SectioningCreates outline sectionsarticle, aside, nav, section
HeadingSection titlesh1–h6, hgroup
PhrasingInline text-level markupa, em, span, img, input, …
EmbeddedImports external resourcesaudio, video, img, iframe, canvas, svg, object, embed
InteractiveUser-activatable controlsa[href], button, details, embed, iframe, label, select, textarea
PalpableVisible / non-empty content expectedMost flow/phrasing with real content

warning

Phrasing parents (like p, h1, span) cannot contain flow-only children such as div or ul. The parser will close the parent early — a common source of mysterious DOM trees.
Mastery Checklist

You have mastered HTML tags when you can do all of the following without looking them up every time:

Build a full page with header/nav/main/aside/footer landmarks and a single h1
Choose phrasing tags for meaning (em vs i, strong vs b, code vs pre) instead of CSS-only spans
Wire every form control to a label; group radios/checkboxes with fieldset/legend
Ship images with alt, width/height, and picture/srcset when responsive or multi-format
Add captions/subtitles via track on video; never autoplay with sound
Mark tabular data with th scope and caption — never use tables for layout
Use details/dialog/popover before custom accordion/modal libraries
Name custom elements with a hyphen and keep light-DOM semantics through slots
Reject obsolete tags (font, center, marquee, frameset, …) in code review
Explain content models well enough to fix invalid nesting from the parser’s point of view

best practice

Treat the validator (W3C / browser DevTools) and an accessibility tree inspector as part of your edit loop. Valid, semantic HTML is the cheapest performance and a11y win available.
$Blueprint — Engineering Documentation·Section ID: HTML-TAGS·Revision: 1.0

Community

Get help on Slack, Discord or VIP

Stuck on a guide? Join the community and ask.