HTML <strong>

HTML Strong <strong> tag is used to define important text in an HTML document.

Example

A simple Strong element is shown in the following example.

index.html

</>
Copy
<!DOCTYPE html>
<html>
    <body>
        <p>normal text <strong>important text</strong></p>
    </body>
</html>

Note: HTML Strong element starts with the tag <strong> and ends with an end tag </strong>.

Default CSS for HTML <strong>

By default, following CSS properties are set for a Strong element.

</>
Copy
font-weight: bold;

Inline Style for HTML Strong Element

We can change the style of Strong element through inline styling using style attribute.

In the following example, we have set the color as red for the Strong element.

index.html

</>
Copy
<!DOCTYPE html>
<html>
    <body>
        <p>normal text <strong style="color:red;">important text</strong></p>
    </body>
</html>

Apply CSS for HTML Strong Element

We can apply CSS for all Strong elements using the strong tag name.

index.html

</>
Copy
<!DOCTYPE html>
<html>
    <head>
        <style>
            strong {
              color:red;
            }
          </style>
    </head>
    <body>
        <p>normal text <strong>important text</strong></p>
    </body>
</html>

Conclusion

In this HTML Tutorial, we learned about HTML <strong> tag and went through different examples that cover defining an HTML Strong element, and styling it.