HTML / Element / Initial coverage

The <button> Element

Status: Initial coverage Scope: HTML Living Standard Checked: 2026-09-12

Technical Summary

The button element represents a button labeled by its descendant content. It is flow, phrasing, interactive, and palpable content, and it is a listed, labelable, submittable, form-associated element.

type is an enumerated attribute. It selects the submit, reset, or button state. Its missing and invalid value defaults are both the Auto state, which is evaluated with the command/commandfor and parent-element conditions when determining whether the button is a submit button.

Definition / Categories

ItemSpecification viewInspection point
MeaningA button labeled by its descendant contentUse text, images, or other phrasing content to communicate the purpose
CategoriesFlow, phrasing, interactive, and palpable contentKeep content categories separate from form-associated categories
Form associationListed, labelable, submittable, and autocapitalize-and-autocorrect inheriting form-associated elementInspect form owner, submission participation, and labeling independently
InterfaceHTMLButtonElementExposes type, form, validity, labels, and related APIs

Structure / Content model

The normal button content model is phrasing content, but it must not contain interactive-content descendants or descendants with a specified tabindex. Nesting another button or link inside a button creates overlapping interaction targets.

<!-- Do not put another interaction target inside -->
<button type="button">
  <span>Open the menu</span>
</button>

The current HTML Standard also defines a special branch for a button used as the first child of a select, including selectedcontent. That branch should not be silently treated as the ordinary page-level button model.

type states and submit-button determination

KeywordStateMain processing
submitSubmit ButtonStarts form submission from the form owner
resetReset ButtonResets the form owner
buttonButtonDoes not select ordinary form submission or reset; used for page actions
Missing or invalidAutoDetermined together with command/commandfor, the parent element, and submit-button conditions

The specification cannot be summarized accurately as “a missing type always submits”. The Auto state is a condition in the submit-button definition: among other conditions, the command attributes must be absent and the parent must not be a select.

Activation behavior

Button activation first checks the disabled state and whether the document is fully active. When a form owner exists, a submit button submits the form and a Reset Button resets it. If the Auto-state branch remains, processing continues through the commandfor target and command state.

if button is disabled:
    return
if button has a form owner:
    if button is a submit button:
        submit the form
        return
    if button is in the Reset Button state:
        reset the form
        return
process commandfor / command or popover targeting

This model is broader than “attach JavaScript to a click”. Forms, disabled controls, commands, and popovers can all affect the activation branch.

Form association / Submission

The form attribute explicitly associates a button with its form owner. name is used for form submission and the form.elements API; value supplies the value used in submission. The button and its value are included only when that button initiated the form submission.

AttributeScopeBoundary
formExplicit form-owner associationAllows the button to be placed outside the form element
formaction / formmethodOverrides the submission URL or methodMust not be used when the element is not a submit button
formnovalidateBypasses constraint validation for that submit operationSeparate from the general form validation model
disabledMakes the control non-interactive and prevents its value from being submittedAffects both activation and submission, not only appearance

Commands / Popover boundary

A button element can define a command. commandfor identifies a target in the same tree, while command selects a defined action such as showing or hiding a popover or closing a dialog. A custom command beginning with -- is an extension point that dispatches a command event to the target.

<button type="button"
        commandfor="help-popover"
        command="show-popover">
  Show help
</button>
<div id="help-popover" popover>Help text</div>

This is not isolated to the button element: it crosses into popover, dialog, CommandEvent, and target-side command-step definitions.

DOM Interface

The button element is exposed as HTMLButtonElement. Alongside type, disabled, form, name, and value, the interface includes willValidate, validity, validationMessage, checkValidity(), reportValidity(), setCustomValidity(), and labels.

const button = document.querySelector('button');
button.type;
button.form;
button.disabled;
button.labels;
button.checkValidity();

Fact / Evidence

Key facts are mapped to their conditions, review status, and evidence locations. Unresolved scope remains visible in the Coverage section below.

Key facts and evidence locations
TypeFactCondition / ScopeStatusEvidence
SPECA button represents a button labeled by its descendant content.When processed as the HTML button element.ReviewedHTML Standard: the button element
SPECtype selects submit, reset, or button states; missing and invalid values use the Auto state.When type is evaluated as an enumerated attribute.ReviewedHTML Standard: type states
SPECThe button content model does not allow interactive-content descendants.Normal button content model; the special select branch is separate.ReviewedHTML Standard: content model
SPECA disabled button stops activation, and submit/reset behavior branches on the form owner and type state.When button activation behavior runs.ReviewedHTML Standard: button activation behavior
SPECA button's value is included in form submission only when that button initiated the submission.The button has a form owner and is the submitter.ReviewedHTML Standard: value and form submission
SPECcommand / commandfor connect a button with command processing for targets such as popovers and dialogs.The target, command state, and target-side command steps apply.ReviewedHTML Standard: button commands

Evidence

  1. HTML Standard: The button element — categories, content model, type, form attributes, activation behavior, and the DOM interface
  2. HTML Standard: Using the button element to define a command — command label, disabled state, and action
  3. HTML Standard: Implicit submission — the form default button and implicit submission
  4. HTML Standard: Form submission algorithm — submitter and form-submission processing boundaries

Implementation Evidence

Implementation observations are recorded separately from normative claims. Unrun items are not treated as reviewed.

Shared fixture / record: Inside <form id="evidence-form" method="get">, the fixture includes an input with no type, explicit for/id association, implicit association with an input inside a label, required, disabled, and submit plus type-omitted button controls. Environment: Chrome 152.0.0.0 (Windows NT 10.0) / checked 2026-09-12.

Implementation evidence register for the button element
TypeReproducible scopeRecord requiredStatus
IMPLDefault type, form owner, and disabled stateChecked with the shared fixture in Chrome 152.0.0 / Windows NT 10.0. Both type="submit" and the type-omitted button returned submit; the submit button's form owner was evidence-form; the disabled button matched :disabled.Reviewed (one Chrome)
WPTTests related to button states, validation, activation, and eventsMapped candidates: button-type.html, button-labels.html, button-validation.html, and button-events.html. On 2026-09-15 in Chrome 152.0.0.0 / Windows NT 10.0, all four selected files passed 18/18 on wpt.live. Unselected WPT coverage and other browsers remain open.Partial (18/18 pass)
AAMBrowser AX observations of button role, accessible name, and disabled stateIn the same fixture's accessibility tree, Save and Default submit appeared as named buttons, and Disabled save appeared with a disabled state.Observed (Chrome AX)

Use the WPT repository for test mapping and HTML-AAM for accessibility criteria.

Coverage / Open Issues

  • CheckedElement meaning, categories, content model, type states, basic activation, form association, and the main DOM API
  • CheckedSpecification entry points for command / commandfor and popover/dialog behavior
  • OpenThe complete form-submission algorithm, successful controls, entry lists, and all implicit-submission branches
  • OpenHTML-AAM, platform accessibility mappings, and assistive-technology observations
  • OpenBrowser implementation results, WPT, historical changes, compatibility data, and Expert-gap Review

This page is initial coverage. It does not claim that every fact about the button element has been verified or that all implementation differences have been resolved.

Related surface

For a beginner-friendly explanation of type selection, form examples, and the boundary with links, see the button element page in Yugien. The relationship between buttons and opening or closing a dialog is covered by the dialog element in Atlas; link conditions and activation behavior are covered by the a element in Atlas; form-control type states are covered by the input element in Atlas.