The <label> tag defines a label for an input element.
Supported In HTML4: No
Supported In HTML5: Yes
HTML4 vs HTML5 Differences: The "form" attribute is new in HTML5.
Attributes
| Title | Values | Description | HTML4 Support | HTML5 Support |
| for | id of another field | Defines which form element the label is for. Set to an ID of a form element. | Yes | Yes |
| form | formname | Defines one ore more forms the label field belongs to. | No | No |
Standard Attributes
All standard attributes are supported.
Event Attributes
All event attributes are supported.
HTML5 Tags
- a
- abbr
- acronym
- address
- applet
- area
- article
- aside
- audio
- b
- base
- basefont
- bdo
- big
- blockquote
- body
- br
- button
- canvas
- caption
- center
- cite
- code
- col
- colgroup
- command
- datalist
- dd
- del
- details
- dfn
- dir
- div