How to add canonical tag to HTML Website

For every website, we have lot of link types like pages, blogs, gallery and many more. In some cases we use to update home page index.html or index.php so if you don't use canonical tag for main link those links should be consider by Google is duplicate. Like that we have number of pages for page nations to display blog posts in pages. The pages should crawl as main blog page only instead of crwaling all pages separatley. 

canonical tag

Like this we have different url strcutres for any domain like https://www, http:/www, www, without any www and https. Website will be open in different ways based on the ip, firewalls, ssl types etc. But all urls are same page but links are different so we need to use canonical tag for main url which you prefer to be index or crwal 

basic structure of canonical tag is 

<link rel="canonical" href="https://www.example.com" />

Video With Live Demo

 

Post a comment

Your email address will not be published. Required fields are marked*