CSS HTML Validator - The All-In-One HTML, XHTML, CSS, Link, SEO, and Accessibility Checker
Home Help: "label" element

The "label" Element


The "label" element can be used to attach information (like a text label) to form controls.

Attributes for "label"
TypeAttribute List
'Standard' Attributes"for"
New HTML5 Attributes"form"


  • Each "label" element should be associated with only one form control.
  • The "placeholder" attribute should not be used as an alternative to a "label" element.

Recommended Links

Accessibility Information & Tips

  • For required form controls, indicate the required status in the control's "label" or "legend". If not indicated by text (like "(required)"), then make sure the meaning of the indicator is explained before it is used. NOTE: Abbreviating "required" to "req." may be confusing. Visit https://www.w3.org/TR/WCAG20-TECHS/H90 for more information.
  • In "select" elements, use "optgroup" to group related "option" elements. Label the option groups with the "label" attribute. Avoid using dummy list entries to delimit groups. Visit https://www.w3.org/TR/WCAG20-TECHS/H85 for more information.

Search Engine Links (for more information)

Help us improve this page: Suggest a link or noteReport a problem