<strong> Strong importance
Text that is important, serious or urgent. Shown in bold by default.
<strong> marks text that is important, serious or urgent; a warning is the typical case. Browsers render it bold.
Pick it for what it means. Bold styling without extra importance, like keywords in a summary, calls for <b> or CSS. Wrapping whole paragraphs in strong defeats the purpose. If everything is important, nothing is.
The strong element in the HTML Living Standard (opens in a new tab) describes it as strong importance, seriousness or urgency. The Strong and Emphasis lesson sets it beside em.
Syntax
<strong>Important text</strong>When to use it
<strong> marks words a reader must not miss: "Do not exceed four tablets" in a medicine leaflet, the payment deadline in a notice, or "Unplug the device first" in repair instructions. Nesting strong inside strong raises the importance level, which suits a rule that outranks the warnings around it.
To choose between the bold-looking and stress elements, ask what the formatting means. Importance or urgency is strong. A spoken stress that changes meaning is em. Keywords that should stand out without extra importance are b. Text relevant to what the reader is doing right now, like a search hit, is mark.
Forms and data pages often misuse strong to fake labels such as "Email:" or row titles. A field label belongs in <label> and a row title in <th>. When you paste formatted text from a word processor, an editor like HTML Editor Tools (opens in a new tab) shows whether its bold became strong or b, so you can fix it.
Live example
Edit the code and watch the preview.
<p><strong>Warning:</strong> the oven is hot.</p>
<p>Please arrive <strong>before 9 am</strong> on the exam day.</p>More examples
Nested importance
Nesting strong increases the level of importance. In these safety rules the outer strong marks the warning, and the inner one marks the single rule that matters most. Reading the rules, you notice the inner rule first.
<h2>Before you clean the toaster</h2>
<p><strong>Let it cool for 10 minutes.</strong> <strong>Always unplug it first. <strong>Never put a knife inside while it is plugged in.</strong></strong></p>Requirement in a form
In a sign-up form, the password rule is the one detail that makes the form fail if it is ignored. The label stays a label, and strong marks only the requirement in the hint text.
<form>
<label for="pw">Password</label>
<input type="password" id="pw" name="pw" minlength="8" required>
<p>Your password must be <strong>at least 8 characters</strong> long.</p>
<button>Create account</button>
</form>Tip: strong means importance. Plain bold styling is b or CSS.
Browser support
strong is supported by every browser and has been part of HTML since HTML 2.0. Browsers render it as bold, with font-weight:bolder in the default stylesheet. The Living Standard redefined it in HTML5 from "strong emphasis" to "strong importance, seriousness or urgency".
Accessibility
Most screen readers do not announce strong by default. A warning therefore needs its importance in the words themselves, for example Warning: ... Which formatting has to be conveyed in markup is covered in the W3C note Understanding Info and Relationships (opens in a new tab).
Common mistakes
Wrong
<strong>Our Services</strong>Right
<h2>Our Services</h2>Bold text does not make a heading. Section titles need a heading element.
Frequently asked questions
What is the difference between strong and b in HTML?
<strong> marks content of strong importance, seriousness or urgency, such as a warning. <b> draws attention without claiming extra importance, as with keywords in a summary or product names. Both are bold by default. Only <strong> says the text counts for more than the text around it. Writing in a visual editor? An online rich text to HTML editor (opens in a new tab) shows whether the bold button produced strong or b.
Does the strong tag help SEO?
Maybe a tiny bit, as a hint that some words are important. Search engines give it very little weight, and keywords wrapped in strong all over the page look spammy. Use <strong> where a human reader should notice the words. Clear headings and good content do far more for you.
Practise it
- Strong and Emphasis (Module 2: Text)
- Project: Recipe Card (Module 2: Text)
- Personal Profile Page (Module 10: Final Projects)