Menu
Wordpress / Wordpress Tutorials

How to Underline in WordPress

Are you looking to underline text in a WordPress post? Unfortunately, you may have noticed that these buttons were removed from the post editor in a WordPress update- WordPress 4.7. Of course, you can still bold or italicise your text. It is important to note that some website users believe that underlined text represents a link, either to another page on your website or someone else’s. However, depending on your content, underlining a word or sentence can show its importance and help grab your reader’s attention.

In this tutorial I will show you simple ways to underline your text in WordPress.

How to underline text in WordPress

Fortunately, when using the WordPress Gutenberg editor, the underline option has not been completely removed. By using a keyboard shortcut, you can underline the specific text by highlighting it and clicking CTRL + U. If you are using macOS, select CMD + U.

Underline text in WordPress

However, some web browsers do not allow for this method. Instead, you can add CSS code to underline your text. To do this, select the three dots on your block of text and click ‘Edit as HTML’. You can also press CTRL + SHIFT + ALT + M to activate the code editor.

Edit text as HTML

Next, use the <span> </span> tag to wrap the text that you want to underline. For example, you can add this inline CSS code:

<span style=”text-decoration: underline;”>Put the text you want to underline here</span>

Underline text in WordPress using inline CSS

Conclusion

This tutorial presented two easy ways to underline in WordPress. If you liked this tutorial, here you can check out some of our other WordPress tutorials.

About Author

Emer has a passion for website development and entrepreneurship, so she is here to give you the information you need to grow your online presence!

No Comments

    Leave a Reply