The HTMLLabelElement interface gives access to properties specific to <label> elements. It inherits methods and properties from the base HTMLElement interface.


Inherits properties from its parent, HTMLElement.

HTMLLabelElement.control Read only
Is a HTMLElement representing the control with which the label is associated.
HTMLLabelElement.form Read only
Is a HTMLFormElement object representing the form with which the labeled control is associated, or null if there is no associated control, or if that control isn't associated with a form. In other words, this is just a shortcut for HTMLLabelElement.control.form.
Is a string containing the ID of the labeled control. This reflects the for attribute.


No specific methods; inherits methods from its parent, HTMLElement.


Browser compatibilityUpdate compatibility data on GitHub

Chrome Edge Firefox Internet Explorer Opera Safari
Basic support Yes Yes 1 Yes Yes Yes
control Yes Yes 4 Yes Yes Yes
form Yes Yes 1 Yes Yes Yes
htmlFor Yes Yes 1 Yes Yes Yes
Android webview Chrome for Android Edge Mobile Firefox for Android Opera for Android iOS Safari Samsung Internet
Basic support Yes Yes Yes 4 Yes Yes ?
control Yes Yes Yes 4 Yes Yes ?
form Yes Yes Yes 4 Yes Yes ?
htmlFor Yes Yes Yes 4 Yes Yes ?

See also

© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.