HTML <strike> Element
The <strike> element was used to display text with a horizontal line through it, commonly called strikethrough text. It was a presentational element that changed the appearance of text without describing why the text had been crossed out.
<strike> element must not be used in new HTML. Use <s> for information that is no longer accurate or relevant, <del> for deleted content, or CSS when the line-through effect is purely decorative.
Historical Syntax
Older webpages could contain markup similar to the following:
<p>Regular price: <strike>$29.95</strike> $19.95</p>
A supporting browser displayed $29.95 with a line through the text. The element indicated how the text should look, but it did not explain whether the text represented deleted information, an outdated value, or simply a visual effect. This code is shown for historical reference only and should not be used in modern HTML.
Attributes
The <strike> element did not have any element-specific attributes. Its historical behavior came from the element itself, which browsers normally rendered with a line through its contents.
Historical Use
The <strike> element provided authors with a simple way to cross out text. It was commonly used for old prices, changed information, corrections, unavailable items, and other content that an author wanted to leave visible while showing that it was no longer current.
The element was purely presentational. The browser knew that the text should appear with a line through it, but the markup did not communicate the reason for that appearance.
This distinction became more important as HTML evolved toward markup that describes the meaning and structure of content while CSS controls its visual presentation.
Why It Became Obsolete
The <strike> element became obsolete because it described only a visual effect. Modern HTML provides elements that can express why text is being shown with a strikethrough, while CSS can provide the appearance when no special meaning is intended.
The <s> element represents content that is no longer accurate or relevant, while <del> represents content that has been deleted from a document. These meanings provide more information than the presentational <strike> element.
When strikethrough is needed only as a visual style, CSS provides the text-decoration: line-through; declaration.
Modern Alternative
The correct replacement for <strike> depends on why the text is crossed out.
Use <s> when information is no longer accurate or relevant:
<p>Regular price: <s>$29.95</s> $19.95</p>
Use <del> when the text represents content that has been deleted from the document:
<p>The meeting begins at <del>2:00 PM</del> 3:00 PM.</p>
If the line-through effect is purely decorative and carries no special meaning, use CSS:
<span class="line-through">Decorative strikethrough text</span>
.line-through {
text-decoration: line-through;
}
Choosing the replacement based on the meaning of the content keeps the HTML more descriptive while leaving purely visual styling to CSS.
Legacy Browser Support
The <strike> element is obsolete, but modern browsers may continue to recognize and display it with its historical strikethrough appearance for compatibility with older webpages. This legacy browser support does not make the element valid for use in modern HTML.
Existing <strike> elements should be replaced with <s>, <del>, or CSS according to the intended meaning of the crossed-out text.
For detailed legacy browser compatibility information, see Can I Use: HTML <strike> Element .
Related Elements
The modern <s> element represents content that is no longer accurate or relevant, while the <del> element represents content that has been deleted from a document. The <ins> element can identify content that has been added to a document.
Specifications
The <strike> element is listed as an entirely obsolete, non-conforming feature in the WHATWG HTML Living Standard . Authors should use <s>, <del>, or CSS depending on the intended meaning and presentation.
