The Different Types of Links

Rachel Costello
Rachel Costello

12 min read

Links can be implemented in a variety of different ways and can take different forms. Here are some of the different types of links that you’ll find across the web.

<a> Links

<a> links are one of the most important tags for SEO, and the majority of internal and external domain linking is achieved by using this HTML tag. An <a> link creates a hyperlink with the a href attribute stating the link’s destination, as well as the anchor text which is the text shown for the clickable link. Here is an example of an <a> link:

<a href=””>Visit!</a>

The anchor text contained within the <a> tag is key for search engines to measure the relevance of the linked-from content to the destination page. When linking internally, you should use relevant and descriptive anchor texts to indicate to search engines the topic the source page is targeting.

Links with commercial anchor text from external websites is one of the core ways that some search engines detect manipulation of links, and this may negatively impact a website or cause penalisation.

Image Links

Search engines use the text within the alt and title tag to understand the context and relevance of the image being displayed to the user. Here is an example of an image tag:

<img src=”examplelogo.jpg” alt=”Example logo of intersecting red squares” />

In order to use an image as a link, you need to embed the <img> tag within an <a> link. Here’s an example of how this would look:

<a href=””>
<img src=”examplelogo.jpg” alt=”Example logo of intersecting red squares” />

For further guidance on using images on your website, take a look at Google’s image publishing guide.

JavaScript Links

It is possible to use JavaScript links, however, they’re not always crawlable for search engines so the recommendation is to use HTML links on pages which are indexable. This will ensure search engines can easily crawl content on the page.

One way to create a crawlable link with JavaScript (assuming that a search engine is able to render the page) is:

var a = document.createElement(‘a’);
var linkText = document.createTextNode(“my title text”);
a.title = “my title text”;
a.href = “”;

A non-crawlable JavaScript link would be a non-<a> link, for instance:

<span onclick=”document.location=’’;”>Link</span>

The main recommendations are to use standard HTML <a> links rather than onclick tags. HTML content should not be dependent on some sort of action or behaviour, especially considering the fact that Googlebot and other search engines can’t execute these actions required to read content the way that a user can. Onclick links are powered by JavaScript and although they can still be crawled, some search engines may not be able to parse them, meaning that they may be devalued in terms of link equity.

For full Javascript crawling recommendations, please see this JavaScript frameworks guide from Google.

Rel Links

The most common use of the “rel” link in SEO is the canonical tag. Here is an example:

<link rel=”canonical” href=””>

You can also serve the canonical tag within the HTTP header, for example:

HTTP/1.1 200 OK
Date: Fri, 21 July 2018 21:00:00 GMT
Link: <>; rel=“canonical”

The canonical tag tells search engines which URL should be indexed and is a solution for content duplication. Duplicate pages can cause a number of issues when it comes to SEO, as PageRank can become diluted between numerous pages.

This can happen in a number of different instances in which you could implement canonicalisation, for example:

Another type of rel link which is commonly used in SEO is the hreflang tag which is used to serve alternative language versions of a page for international websites. Here is an example of an hreflang rel link:

<link rel=“alternate” href=“” hreflang=“en-us” />


Nofollow Links

Nofollow links can be used to prevent search engines from accessing pages that are essentially a waste of time, which is helpful for improving a site’s crawl budget. Without the use of nofollow, search engine robots will try to follow all internal links on a site. Reducing the number of low-value pages robots need to crawl will increase the chance of higher value content being crawled more frequently.

Webmasters can use rel=”nofollow” to indicate to search engines crawlers that a particular link should not pass any equity to other pages, and should be disregarded from a discovery and equity perspective. Nofollow tags are a webmaster’s way of preventing robots from following links on a specific page or a specific links by using the code snippets provided below.

In September 2019, Google announced an update to their nofollow directive and introduced two new link attributes, these are:

In addition, all links marked with nofollow, sponsored or ugc are now treated as hints regarding which links to consider in search and when crawling, as opposed to just a signal, as was used previously for nofollow. You can find out more about this update in our post which also covers the impact of these along with expert insights.

There are two ways of implementing nofollow links:

1. Page-level Nofollow Meta Tag – With a page-level nofollow tag, search engines will not attempt to crawl any links on the page, and will not pass any link authority to them

<meta name=”robots” content=”nofollow” />

Take a look at our guide to URL-level directives for more information on page-level tags such as nofollow.

2. Link-specific Nofollow Tag – On a link-level nofollow, search engines will not attempt to crawl the specific link and will not pass any link equity to it. Google does not redistribute the PageRank meant for this link to other links on the page (i.e. that value is lost by using a nofollow). Other search engines may behave differently, however.

<a href=”example.php” rel=”nofollow”>sign in</a>

Types of Links that Should be Nofollowed

It won’t always be the case that you’ll want search engines to follow every single link on your site, whether that’s pointing internally or externally. Here are some examples where you may want to implement nofollow links:

Types of Pages that Should be Nofollowed

Not all pages are valuable enough to warrant being crawled by search engines, but they may still need to exist for your users. Here are some of the types of pages that typically have nofollow links directed at them:

Nofollow can be useful in these situations, however, it doesn’t always hurt for these types of pages to be crawled by Google, as Matt Cutts explained.

Bear in mind that ensuring the site isn’t linking to poor quality content and focusing on having great UX and site architecture should be the priority. So the use of nofollow should be limited. Here’s what Google has to say on the matter:

“A solid information architecture — intuitive navigation, user- and search-engine-friendly URLs, and so on — is likely to be a far more productive use of resources than focusing on crawl prioritization via nofollowed links.”

Next: Handling Broken & Redirected Links


Rachel Costello
Rachel Costello

Rachel Costello is a Former Technical SEO & Content Manager at Deepcrawl. You'll most often find her writing and speaking about all things SEO.

Choose a better way to grow

With tools that will help you realize your website’s true potential, and support to help you get there, growing your enterprise business online has never been so simple.

Book a Demo