What is a “nofollow” link and how to add it in WordPress?

Published in Community.

The relevance of a website depends on countless factors. But the part that carries more weight in terms of SEO is inbound and outbound links.

A website is relevant if the websites that link it are. For each link it receives, it also receives a fraction of the relevance of the websites that link it. In turn, outgoing links of the web will transfer the relevance of that website to the destination websites of the links.

This link scheme makes the web a cloud of points linked together, where relevance flows through the links between points. Google used this scheme to define PageRank, the original algorithm for scoring web pages and ordering them in search results.

What is a “nofollow” Link?

Returning to the topic that focuses this post, the links can have an additional attribute called “rel” whose value can be, among others, “nofollow”. If we create a link and set it to “nofollow” we will be indicating to the search engine that it shouldn’t transfer relevance from our website to the website linked.

Does this mean that to rank higher in search results we should always put rel="nofollow" in our links? No!

Linking external content is one of the best practices you can do to enrich your content, expand, and improve the user experience. But nevertheless, there are times when you link unreliable sources or use affiliate links that have little to do with the final relevance of your website. In such cases, using rel="nofollow" is interesting.

How to Create a “nofollow” Link in the WordPress Editor

To create a “nofollow” link in WordPress the first thing we need is to create a link as we would normally do. In the WordPress block editor we select one or more words and click on the button to create a link:

By adding a link in the WordPress block editor you can indicate if you want the link to open in a new tab or not.
By adding a link in the WordPress block editor you can indicate if you want the link to open in a new tab or not.

There we have the option to add the URL we want to link to. In addition, we can select if we want the link to open a new tab (something always recommended for external links).

In the current version of the WordPress block editor there is no way to add the “nofollow” value in the links directly from the user interface, so you have to go to edit the block with the link from the HTML editor. To do so, click on the three-vertical-dots button of the block and select the option “Edit as HTML”:

To add the value «nofollow» in a link you have to go to edit the block as HTML.
To add the “nofollow” value in a link you have to go to edit the block as HTML in WordPress.

This will momentarily convert the block into an HTML block with the content to be edited. The link will appear as a common <a> tag. Then we must add the rel="nofollow" attribute inside the <a> tag, as you see below:

Once you are editing the HTML of the block, you just have to add rel = "nofollow" inside the tags of your links.
Once you are editing the HTML of the block, you just have to add rel="nofollow" inside the <a> tags of your links.

Once you’re done, you can go back to edit the block visually. Just click on the three vertical dots icon again and select “Edit visually”:

When you have finished editing the HTML of your links, return to the visual editor of the block editor.
When you have finished editing the HTML of your links, return to the visual-editing mode of the block editor.

This way, you have your link with the rel="nofollow" attribute within your content. This will prevent the search engine from transferring your relevance to a linked website.

How to Add a “nofollow” Link in The WordPress Menu

We can also do the same in our menus. In WordPress, if we go to Appearance and there we choose Menus, we enter the editor of the menus of our web page.

In this editor we have the possibility to add items to menus that are links to external web pages. To do this, select the option to add a custom link. There you can create a menu item with an external URL.

Before you can indicate that this menu is a “nofollow” link, though, you have to open the screen options found in the upper-right corner:

Open the screen options in the WordPress menu editor to enable the Link Relationship (XFN) option.
Open the screen options in the WordPress menu editor to enable the option “Link Relationship (XFN)”.

and activate an option named “Link Relationship (XFN)”.

Once active, if you re-edit the menu item you just added in your menu you will see that a new field appears with the name “Link Relationship (XFN)”. Add the “nofollow” value there:

By activating the "Link relationship (XFN)" option, you can add the "nofollow" value to the menu items.
By activating the “Link Relationship (XFN)” option, you can add the “nofollow” value to the menu items.

Save the menu and you’re done!

How to Manage All Links in WordPress

Now that you’ve seen how to add the “nofollow” attribute in your links, I’m pretty sure you realized that doing it by hand for all your links can be pretty tedious… Fortunately, there are plugins that help you configure the behavior of your links. The one that I recommend you to look at is External Links, which will facilitate this task. You just have to go to the External Links tab and there indicate if the behavior has to be follow or nofollow:

The WP External Links plugin allows you to configure if you want all your external links to have the attribute «nofollow».
The WP External Links plugin allows you to configure if you want all your external links to have the attribute “nofollow”.

Whether you do it manually or use a plugin, knowing the semantics behind the “nofollow” value and acting accordingly when adding links on your website is important to improve the SEO of your content.

Have you taken into account the “nofollow” behavior in the contents of your website? Leave us a comment below with your opinion about it.

Featured image of Jehyun Sung on Unsplash.

PoorNot badGoodGreatExcellent (No Ratings Yet)
Loading...

Leave a Reply

Your email address will not be published. Required fields are marked: •

I have read and agree to the Nelio Software Privacy Policy

Your personal data will be located on SiteGround and will be treated by Nelio Software with the sole purpose of publishing this comment here. The legitimation is carried out through your express consent. Contact us to access, rectify, limit, or delete your data.