Void element
A void element is an element in HTML that cannot have any child nodes (i.e., nested elements or text nodes). Void elements only have a start tag; end tags must not be specified for void elements.
The void elements in HTML are as follows:
-
-
-
-
- Deprecated
-
-
Self-closing tags () do not exist in HTML.
Self-closing tags are required in void elements in XML, XHTML, and SVG (e.g.,
In SVG and MathML, elements that cannot have any child nodes are allowed to be marked as self-closing. In such cases, if an element’s start tag is marked as self-closing, the element must not have an end tag.