iron, iron chain, connection

How To Remove Nofollow From Links, WordPress (For Beginners With Pictures)

If you are new to SEO and WordPress, then the constant alert from site audits telling you that you have a no-follow attribute on your links can be troublesome. This can be a problem because you will not have any “link juice”.

To resolve this issue, you will need to use the code I have provided in this post. Either add it at the bottom of your header PHP file or install the Insert Header and Footer plugin and put the code into the header section. If anything should go wrong, you can easily remove the code. This code will remove all no-follow attributes across your site.

To solve this exasperating problem read on!

Why do I have the no-follow attribute on my links when I never put them there?

We all know that when we add a specific link to a post you will have three possible options of telling a crawler what to do with the link.

When you add a link the options pop up and you may have never ever checked the nofollow tab but you are still getting the alert that your links have the nofollow tag.

This happens because WordPress has by default added the no-follow tag into the WP code. So whether you check the tab or not the you will not be getting link juice any time soon.

It is frustrating I know because it took me two entire days to fix the issue after which I wrote this post to help anyone who may have similar problems.

As you can see above my link did not have a no-follow on but any site audit would say that I had a no-follow on ALL my links.

How to get rid of the no-follow attribute

There is one easy peezy way you can get rid of the Nofollow attribute by simply installing a plugin for headers and footers.

The plugin is called Insert Headers and Footers and it is made by WPBeginner who is an awesome company for all things WordPress.

After you have installed the plugin in the WordPress back-end then copy-paste your code into the header file in the plugin.

Here is the code for the No-follow removal

<script>
jQuery('document').ready(function(){
        jQuery("a[rel~='nofollow']").each(function(){
                jQuery(this).attr('rel', jQuery(this).attr('rel').replace('nofollow',''));
        }); 
}); 
</script>

Here are step-by-step instructions on how to remove the no-follow attribute

Firstly go to your WordPress back-end and click on plugins.

Now click on “Add New”.

Now type “Insert Headers and Footers” into the plugin search bar. Click on “Install Now” to install your plugin. Now click on “Activate” and now your plugin will be active.

Now go to “Settings” in the sidebar of your WordPress back-end.

Click on Insert Headers and Footers.

Now copy paste the code I have provided into the header section.

Always remember to scroll down and click the “Save” button (because I always forget to press save 😉 ).

What are the No-follow link attributes?

A no-follow tag on a link is a signal to crawlers that the website you link to is either not reputable or your website does not deem it noteworthy. It is important to signal to crawlers that you do not associate your site with disreputable sites. From an SEO standpoint, it is better to link out to authoritative websites. Like Wikipedia, the official papers of any medical site and so on.

The no-follow attribute is often used for advertisement links and websites that you quoted from but you are not willing to vote for their authority.

Final Thoughts

Today I have written the shortest post that I have ever written. If I missed anything or you have any further questions please feel free to ask me in the comments below.