HTML <b> Element

The <b> element draws attention to text without indicating that the text has additional importance, emphasis, or a different tone. Browsers typically display its content in bold text.

Syntax

<b>Text that should receive attention</b>

The opening and closing tags are both required.

Attributes

The <b> element supports the global HTML attributes. It does not have any element-specific attributes.

Example

The following example uses the <b> element to draw attention to product names without indicating that they are more important than the surrounding text:

<p>Our most popular models are the <b>Mountain Explorer</b> and the <b>Trail Runner</b>.</p>

The browser typically displays the product names in bold text.

Try It Yourself

Edit the text inside the <b> element to see how the browser draws attention to selected words without changing their semantic importance.

Play in Editor

Usage Notes

Use the <b> element when text needs to attract the reader's attention for a practical purpose without conveying additional importance or emphasis. Examples can include keywords, product names, or other text that should stand out from the surrounding content.

Although browsers normally display <b> text in bold, the element should not be used simply to make text bold. When the goal is only visual styling, use the CSS font-weight property instead.

Use <strong> when the text has strong importance, seriousness, or urgency. Use <em> when the text requires stress emphasis.

The meaning of <b> has changed from earlier versions of HTML. It was historically associated with boldface presentation, while modern HTML gives it the semantic purpose of drawing attention without adding importance.

Accessibility

Do not rely on the bold appearance normally given to <b> to communicate importance or essential information. The element does not indicate strong importance to assistive technologies.

If the meaning depends on importance or emphasis rather than simply drawing visual attention, use a more appropriate semantic element such as <strong> or <em>.

Browser Support

Baseline: Widely available indicates a feature has been supported by core browsers for at least 30 months. At this stage, the feature is considered stable and safe for most websites to use without needing to worry about compatibility issues or fallbacks, as it is supported by the vast majority of users' devices and browser versions.

For detailed browser compatibility information, see Can I Use: HTML <b> Element .

<strong> - Indicates text with strong importance, seriousness, or urgency.

<em> - Indicates text with stress emphasis.

<mark> - Represents text marked or highlighted because of its relevance in the current context.

Specifications

HTML Living Standard: The <b> Element