The HTML <hr> tag
The HTML <hr> element represents a thematic break between paragraph-level content: a shift in topic or scene. It is a void element rendered as a horizontal rule; it carries meaning, so do not use it purely as a decorative line.
Overview
The <hr> element marks a thematic break between paragraph-level content: a shift in topic within a section, or a scene change in a story. Browsers render it as a horizontal rule, but its purpose is semantic, not decorative.
All of its old presentational attributes (size, color, noshade, width, align) are obsolete. Style it entirely with CSS instead, setting its border, height and color.
For a divider that is purely decorative and carries no thematic meaning, do not use <hr>; apply a CSS border to the surrounding element instead. Reserve <hr> for genuine topic shifts so it stays meaningful.
Syntax
<p>End of one topic.</p>
<hr>
<p>Start of another.</p>
Example
<p>First topic.</p>
<hr style="border:none;border-top:1px solid #cbd5e1;">
<p>Second topic.</p>
Best practices
Frequently asked questions
What does the hr element mean?
How do I style the hr element?
Should I use hr just for a decorative line?
<hr> for real topic breaks.Does hr need a closing tag?
<hr> with no closing tag.