On the values that rel
can have in a link, you can read more in the MDN documentation (partially in Spanish at the time of writing this response) or directly in the W3C documentation for HTML5 standard and the a
element (in English).
What rel
indicates is the relationship between the document that contains the link and the linked document. It does not affect how the browser will render those links , although it can be used in the attribute selector in CSS (eg: a[rel="valor"]
) to give them a specific style.
For SEO helps to make sense (semantics) to the page and can be helpful for social engineering (for example by specifying the author) or to better classify / index contents and their relationships with other pages / sites.
Now I'm going to go into a little more detail about nofollow
and external
.
nofollow
The first thing that should be clarified is that nofollow
does not mean that the bots of the search engines will not follow the link, in fact, most likely they will follow it. According to the HTML5 definition (my translation):
The keyword nofollow
indicates that the link is not endorsed by the original author or publisher of the page, or that the link to the referenced document was included mainly by a commercial relationship between people affiliated with both pages.
Bearing that in mind, setting a nofollow
to a link will not affect the destination's traffic (the link can be visited by users) or its discovery by the search engines (what not to follow is a "recommendation" for the bot) but, as they say in the comments, it can affect (negatively) the page that contains the link. The ranking of a page will depend in part on the analysis of the linked sites on that page .
For example, if a search engine considers that "Page Z" is bad because it has spam and spyware, and your "Page Y" has a link to that "Page Z", then that search engine will penalize you by linking to a page that you know is bad. That is why it is important to use nofollow
in some links.
As a general rule, the recommendation would be that you do not trust any link that comes from a user input (for example in the comments of a blog or in the responses of a forum) and add nofollow
to save you problems .
This Google article (in Spanish) lists three important cases in which use nofollow
is good and recommended:
-
If you do not trust the linked content . Basically for the above, to " avoid transferring PageRank values unconsciously to the" undesirable neighborhoods "of the Web ". It is also mentioned as a method to dissuade distributors from spamming (you can manually remove the
nofollow
for links that you have checked).
-
If it's a payment link . Search engines want paid / commercial links to be identified and valued, " in the same way that online and traditional consumers value commercial relationships being revealed (eg, when a newspaper ad includes the 'Ad' header) "
-
To give tracking priority . For example, so that bots do not follow the links to "sign up here" or "sign in" sections, because " search engine bots can not access or register as members of your forum ".
external
In the particular case of the value external
what is being said is that the document / linked page is a different site. If the user presses it, it will leave the current site to navigate to a different one.
It will not affect you when it comes to SEO, it only adds some semantic information (although I do not really know what the value of that information is because the search engine will automatically detect if the link is external or not. ).
Because of the comments I have found online, it seems that in the past some browsers treated rel="external"
as if it were a target="_blank"
and there would be the link in a new window (although I have not found anything official about that).