What HTML element defines a horizontal rule?

The story behind the answer

The HTML element that defines a horizontal rule is <hr>. It marks a thematic break between sections of content, such as a change of topic or scene.

In early HTML, browsers commonly displayed <hr> as a visible horizontal line, so it became known as a “horizontal rule.” Modern HTML emphasizes its meaning rather than its appearance. A browser may still render a line by default, but CSS controls its color, thickness, spacing, and border style.

The <hr> element is a void element, so it does not contain text and does not need a closing tag. It is different from <br>, which merely forces a line break, and from <div>, which is a generic container without inherent thematic meaning. If you need a decorative line with no semantic separation, a CSS border may be more appropriate.

Source: Wikipedia · fact-checked Aug. 2026

Add question to a list

Choose a list to keep this question in: