HTML: <hr>
XHTML: <hr/>  or  <hr />

Adds a horizontal rule to the page that can be used as a divider between sections of content. It is a block-level element.

This is an example of a presentational HTML element. In HTML5, this element is included but has been redefined as a "paragraph-level thematic break." Developers who want a purely decorative horizontal rule should opt for using style sheets to add a border on the top or bottom edge of a block element.

Start/End Tags

This is an empty element. In HTML, the end tag is forbidden. In XHTML, the element must be closed with a trailing slash as just shown. Developers may include a space character before the slash for backward compatibility with older browsers.


  • HTML 4.01
  • HTML5


Values: center | left | right
Deprecated. Not in HTML5. If the rule is shorter than the width of the window, this attribute controls horizontal alignment of the rule. The default is center.


Values: None in HTML. (noshade="noshade" in XHTML)
Deprecated. Not in HTML5. Displays the rule as a solid bar with no shading.


Values: number
Deprecated. Not in HTML5. Specifies the thickness of the rule in pixels.


Values: number or number%
Deprecated. Not in HTML5. Specifies the length of the rule in pixels or as a percentage of the page width. By default, rules are the full width of the browser window.
<p>These are notes from Thursday.</p>
<p>These are notes from Friday.</p>
<p>These are notes from Thursday.</p>
<hr />
<p>These are notes from Friday.</p>

Rendered Example

These are notes from Thursday.

These are notes from Friday.