- Trending Categories
- Data Structure
- Operating System
- MS Excel
- C Programming
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to create nofollow link using HTML5
In simple language, a “nofollow” link is a link which tells the google search engine to not to follow the particular link. As when it comes to the search engine optimization of the page, time the links play a vital role in the ranking of the page. In the HTML5 we can make any link a nofollow link by assigning the nofollow attribute to the anchor tag.
The basic syntax used to create any link a nofollow link is −
<a href="# rel="nofollow"></a>
The main approach to make a nofollow link is by adding the “rel” attribute to the anchor tag of the HTML5. The value of the rel attribute is assigned as nofollow which makes the link or Uniform Resource Locator (URL) a nofollow link. As the nofollow value is set in the rel attribute, in which rel means relation which tells the relation between the current webpage and the link which is linked in the href attribute.
Step 1 − Create a HTML boilerplate in any text editor, which can be Notepad, Notepad++, VS Code, etc.
Step 2 − Add the anchor tag inside the body tag of HTML.
Step 3 − Now add an attribute to the anchor tag which is a rel attribute, assign the value nofollow to it.
Step 4 − Add any link in the href attribute of the anchor tag.
Step 5 − Now the link which we had assigned in the href attribute is nofollow.
The below example shows a nofollow link which is contained in the href attribute with the nofollow value in rel attribute.
<html> <head> <title>Nofollow Link</title> </head> <body> This is a <a href="https://tutorialspoint.com/" rel="nofollow">Nofollow Link</a> </body> </html>
The given below image shows the text with the anchor link, so as from the above example we have created a no follow link, so in the below the link is a no follow link.
To check the below link is a no follow link in your browser right click on the link or Ctrl+Shift+I this will open a view page source or inspect section. In it check whether the anchor element tag contains a rel attribute or not. If a tag contains rel attributes then the link is no follow. There are many good cases of the nofollow link as the name suggests that this link will not be followed by the google engines, which will make the page load fast with a better ranking and no penalized google search engine ranking. As the ranking of the page is also maintained and increased by the link, the crawlers scan the web content to make our web page rank. The rel attribute also contains many values such as search, prev, alternate, norefer, etc.
Kickstart Your Career
Get certified by completing the courseGet Started