Skip to main content
Practice

SEO Meta Tags - canonical, robots

When you want to prevent search engine penalties for duplicated content across multiple web pages or hide certain pages from search engines, there are techniques you can use.

Let's explore the meta tags canonical and robots that are utilized in these situations.


A canonical link informs the search engine which page is considered the "official" version when there is duplicate content across multiple pages.

Example of using a canonical link
<head>
<link rel="canonical" href="https://example.com/original-article" />
</head>

This canonical tag tells the search engine that the page "https://example.com/original-article" is the definitive version among the duplicated content.


robots meta tag

The robots tag is used to instruct search engines on whether they are allowed to index a specific page or not.

If you don't want certain documents or information to be shared with others, you can use the robots meta tag as shown below.

Example of a robots meta tag
<head>
<meta name="robots" content="noindex, nofollow" />
</head>

Want to learn more?

Join CodeFriends Plus membership or enroll in a course to start your journey.