Add Nofollow and Target _blank To All External Links

Add Nofollow and Target _blank To All External Links

"Nofollow" provides a way for webmasters to tell search engines "Don't follow links on this page" or "Don't follow this specific link."

Nofollow and Target _blank To All External Links

Why to Nofollow external links? 

Nofollow attribute appeared in the page-level meta tag, and instructed search engines not to follow (i.e., crawl) any outgoing links on the page.. In simple words, it does not allow to pass the PageRank
to any other external link.

"Target" attribute specifies where to open the linked document.

  • _blank - Opens the linked document in a new window or tab.
Why to open external links in a new window? 

Anchor links have a target attribute which controls what happens when that link is clicked. One of the possible values of that attribute is _blank, which tells the browser to open a new window. The reason for opening external links in a new window can vary person to person. Many peoples do this because they want there visitors to remain on there site.

How to Nofollow and Target _blank To All External Links?
  1. Go to Your sites header section i.e. Header.php for wordpress and Edit html if you are using blogger.
  2. Search for </head> 
  3. Paste below codes just above </head> and save changes.
<script src='' type='text/javascript'></script>
<script type="text/javascript">
jQuery(document).ready(function () {
jQuery('a[href*="http://"]:not([href*=""])').attr('rel', 'nofollow');
jQuery('a[href*="https://"]:not([href*=""])').attr("target", "_blank");
Customization : 

  • Change Blue background text with your site URL.
  • Remove Script in Green background if you have already added it.

No comments:

Post a Comment