TechnoSubrat SEO Tools

Canonical Tags: When You Need Them and How to Add Them

Canonical Tags: When You Need Them and How to Add Them

A canonical tag is a line of HTML, <link rel="canonical" href="...">, that tells Google which URL is the main version of a page when the same or very similar content is available at several addresses. You need one on every indexable page, pointing to itself, plus on any duplicate or parameter URL, pointing to the original.

Key takeaways

  • Every page you want in Google should carry a self-referencing canonical tag with its full, absolute URL.
  • Duplicate versions (tracking parameters, filters, print pages, HTTP or www variants) should point their canonical to the one version you want ranked.
  • Google treats the canonical tag as a strong hint, not a command, so your redirects, internal links and sitemap must agree with it.
  • Most WordPress sites get canonical tags automatically, but plugins, themes and page builders often set them wrongly.
  • Search Console’s URL Inspection tool shows both the canonical you declared and the one Google actually chose.

What is a canonical tag and why does it matter?

A canonical tag tells search engines “this is the preferred address for this content”, so Google indexes and ranks one URL instead of splitting attention across several copies. Without it, Google has to guess, and it does not always guess the URL you would choose.

Duplicate URLs are far more common than most business owners expect. The same product page might load at all of these addresses:

  • https://example.in/blue-kurta/
  • https://example.in/blue-kurta/?utm_source=whatsapp
  • https://www.example.in/blue-kurta/
  • https://example.in/shop/women/blue-kurta/

To you these are one page. To a search engine they are four URLs with identical content. Canonicalisation is simply the process of picking one of them as the representative version. According to Google’s Search Central documentation on canonical URLs, the rel="canonical" link element is one of several signals Google uses for this, alongside redirects and sitemaps.

Duplicate content on your own site is not a penalty. The real costs are quieter: Google may show the wrong URL in results (for example, one with a tracking parameter), links pointing to different versions get split, and crawl time gets wasted on copies instead of your new pages.

Do I need a canonical tag on every page?

Yes, in practice every indexable page should have a self-referencing canonical, meaning the tag points to the page’s own clean URL. It costs nothing and protects the page whenever someone links to it with extra parameters attached.

Here is how I decide what each type of URL needs:

Type of URLWhat the canonical should point toExample
Normal page, post or productItself (self-referencing)/seo-guide/ → /seo-guide/
URL with tracking parametersThe clean URL/seo-guide/?utm_source=fb → /seo-guide/
Sorted or filtered category viewThe main category page (if the content is essentially the same)/shoes/?sort=price → /shoes/
Product reachable through two category pathsOne chosen product URL/sale/red-saree/ → /red-saree/
Printer-friendly or AMP-style copyThe main article/print/seo-guide/ → /seo-guide/
Paginated archive (page 2, 3…)Itself, not page 1/blog/page/2/ → /blog/page/2/
Content republished on another siteYour original article (if the other site agrees to add it)Partner site → your post

The paginated row catches many people out. Page 2 of your blog lists different posts from page 1, so it is not a duplicate. Pointing every page’s canonical to page 1 can stop Google from discovering the older posts listed deeper in the archive.

Check your website for this in 2 minutes

Our free SEO audit scans up to 50 pages and shows exactly which pages have this issue, with step-by-step fixes and a PDF report.

Run a free SEO audit →

How do I check which canonical tag a page is using?

The quickest way is to view the page source and search for “canonical”.

  1. Open the page in Chrome or Edge, right-click and choose View page source (or press Ctrl+U).
  2. Press Ctrl+F and search for rel="canonical".
  3. Check there is exactly one canonical tag, that it sits inside the <head>, and that the URL is complete, including https://.
  4. Copy the canonical URL into a new tab and make sure it loads with a normal 200 status, not a redirect or a 404 error.
  5. Repeat on a URL with a parameter added, such as ?test=1, and confirm the canonical still points to the clean version.

Checking pages one by one gets slow on a bigger site. Our free SEO audit tool reads the canonical tag along with titles, meta tags and headings, so you can spot missing or mismatched canonicals in a single report.

For the most reliable answer, use Google Search Console. Paste the URL into the URL Inspection tool at the top of Search Console and open the page indexing details. You will see two fields: the user-declared canonical (what your tag says) and the Google-selected canonical (what Google actually decided). If they differ, Google has overruled your tag, and the next sections explain why that happens.

How do I add a canonical tag correctly?

Place a single <link rel="canonical"> element inside the page’s <head> section, using the full absolute URL of the preferred version. That one line is all the code you need.

Example: on the page https://example.in/blue-kurta/?colour=navy, the head section should contain:

<link rel="canonical" href="https://example.in/blue-kurta/" />

Follow these rules when you add it:

  1. Use absolute URLs. Write https://example.in/blue-kurta/, not /blue-kurta/. Relative URLs are easier to break during migrations or on staging copies.
  2. Match your preferred format exactly. HTTPS, www or non-www, and trailing slash should all match the version your site actually serves.
  3. Keep it in the head. A canonical placed in the body is ignored. Some scripts and page builders accidentally push head elements into the body, so check the rendered source.
  4. Only one per page. If two tags point to different URLs, search engines may ignore both.
  5. Point to a page that is indexable. The target should return a 200 status, not be blocked by robots.txt and not carry a noindex tag.

For files that have no HTML head, such as PDFs, Google also supports sending the canonical in an HTTP Link header.

Adding canonical tags in WordPress

WordPress core adds a self-referencing canonical tag to single posts and pages automatically. SEO plugins such as Yoast SEO and Rank Math take over this job and extend it to categories, tags and other archives, so you rarely need to touch code.

To set a custom canonical on one page in Yoast SEO, open the page in the editor, go to the Yoast SEO panel, open the Advanced section and paste the preferred URL into the canonical URL field. The Yoast help guide on canonical URLs walks through this with screenshots. Rank Math has a similar field under its Advanced tab. Leave the field empty for normal pages, because the plugin already outputs a correct self-referencing tag.

One WordPress warning: run only one SEO plugin. When I audit sites at TechnoSubrat, two SEO plugins (or a theme with built-in SEO features plus a plugin) is one of the most common causes of duplicate canonical tags in the page source.

Why did Google choose a different canonical than mine?

Google picks a different canonical when other signals on your site contradict your tag. The canonical tag is a strong hint, but Google weighs it against redirects, internal links, sitemap URLs, HTTPS and how similar the pages really are.

In Search Console’s Page indexing report, this shows up as “Duplicate, Google chose different canonical than user”. Two related statuses are worth knowing:

  • Alternate page with proper canonical tag: usually fine. Google found a duplicate, saw your canonical and respected it.
  • Duplicate without user-selected canonical: Google found duplicates but you had not declared a preferred version, so it picked one itself.

Common reasons Google overrules your choice, and what to do about each:

ProblemLikely causeFix
Google picks the HTTP or www versionThe other version still loads instead of redirectingAdd a site-wide 301 redirect to your preferred version
Google picks a parameter URLMenus or internal links use the parameter versionUpdate internal links to the clean URL
Google ignores the tag entirelyCanonical points to a redirecting, 404 or noindex pagePoint it at a live 200 page that can be indexed
Canonical pointing to an unrelated page is ignoredThe two pages have quite different contentOnly canonicalise true duplicates; use a redirect if the old page is gone
Sitemap lists the duplicate URLsPlugin or manual sitemap includes non-canonical versionsList only canonical URLs in the XML sitemap

If HTTP and HTTPS versions both still load on your site, fix that first. My guide to setting up and testing an HTTP to HTTPS redirect covers the steps, and once the redirect is in place, most canonical conflicts between those versions disappear.

What are the most common canonical tag mistakes?

The most damaging mistake is pointing many pages at the homepage or another single URL, because Google may then drop those pages from its index. Most other mistakes come from plugins, migrations or copy-pasted templates.

  1. Every page canonicalised to the homepage. Often caused by a hard-coded tag in a theme header. Each page should point to itself.
  2. Staging or old domain in the canonical. After a redesign, tags still point to staging.example.in or the old domain. Search your page source for any domain that is not your live one.
  3. Mixing canonical and noindex on the same page. A noindex tag says “do not index this”, while a canonical pointing elsewhere says “this is a copy of that page”. The two send mixed messages, so pick one approach per page.
  4. Using robots.txt to hide duplicates. If Google cannot crawl a URL, it cannot see the canonical tag on it. Google’s documentation advises against using robots.txt for canonicalisation.
  5. Canonical chains. Page A points to B, and B points to C. Point every duplicate directly at the final preferred URL.
  6. Canonical added only by JavaScript, or changed by it. Google can process JavaScript, but putting the tag in the original HTML is more dependable.
  7. Using canonicals instead of redirects for moved pages. If a page has permanently moved and users do not need the old one, a 301 redirect is the stronger and cleaner signal.

A simple test I use: if a visitor landing on the duplicate URL would be equally happy on the canonical URL, the canonical is probably right. If they would be confused, the pages are not true duplicates.

Canonical tag, 301 redirect or noindex: which should I use?

Use a 301 redirect when the duplicate URL should not exist for visitors, a canonical tag when visitors still need the duplicate URL to work, and noindex when a page should be kept out of search entirely. Choosing the right tool prevents most canonical conflicts.

SituationBest optionWhy
Old page moved to a new URL301 redirectVisitors and search engines both land on the new page
HTTP to HTTPS, or www to non-www301 redirectNo reason for the other version to load at all
Tracking, sort or filter parametersCanonical tagThe URL must work for users but should not be indexed separately
Same product in several categoriesCanonical tagShoppers can browse either path; Google sees one product
Thank-you pages, internal search results, login pagesNoindexThese pages are not duplicates, they just do not belong in search

Canonical problems are a frequent reason why the right page does not appear in search. If you are still struggling to get pages seen at all, work through my checklist for when your website is not showing on Google, which covers indexing blocks alongside canonicals.

When should I get expert help with canonical tags?

Get help when Search Console reports hundreds of “Google chose different canonical” pages, after a site migration, or when you run an online store with filters and variants. These cases usually involve redirects, templates and sitemaps together, not one tag.

Ecommerce sites, multi-language sites and sites built on custom code are where I see canonical issues cause real traffic loss, because a single template mistake repeats across thousands of URLs. A structured review, such as the steps in our technical SEO checklist for business websites, will show whether canonicals are the actual problem or just one symptom of a bigger crawl issue. If you would rather hand it over, our SEO services in India include technical fixes like canonical clean-ups, redirect mapping and sitemap corrections.

What should I do next?

Start by checking the canonical tags on your five most important pages: the homepage, your main service or category pages and your best-selling product or top blog post. Make sure each one points to itself with the correct HTTPS URL.

  1. Run your site through the free SEO audit tool to see missing, duplicate or mismatched canonical tags at a glance.
  2. Open the URL Inspection tool in Search Console for your key pages and compare the declared and Google-selected canonicals.
  3. Check the Page indexing report for “Duplicate, Google chose different canonical than user” and fix the causes using the table above.
  4. Confirm your XML sitemap lists only canonical URLs and that your internal links use the same versions.

If the report shows problems you would rather not untangle yourself, contact Subrat Patnaik and I will review your canonical setup and fix it alongside any related redirect or indexing issues.

Frequently asked questions

Is a canonical tag a directive or a hint?

Google treats a canonical tag as a strong hint rather than a strict command. It usually follows your choice, but it can pick a different URL if other signals disagree, such as redirects, internal links, sitemap entries or HTTPS versions. Keeping all of those signals consistent with your canonical tag is the best way to make sure Google respects it.

Can a canonical tag point to a different domain?

Yes. Cross-domain canonicals are supported and are useful when your article is republished on a partner site. The partner adds a canonical tag on their copy pointing to your original URL, which tells Google that your page is the source. You cannot add it for them, so agree on this before allowing syndication.

Does a missing canonical tag hurt rankings?

A missing canonical tag is not a penalty on its own. Google will still choose a canonical for each set of duplicates. The risk is that it picks a version you did not want, such as a URL with tracking parameters, and that link signals get split between copies. Adding self-referencing canonicals removes that guesswork at almost no cost.

How long does Google take to respect a new canonical tag?

There is no fixed time. Google has to recrawl both the duplicate and the preferred page before it updates its choice, which can take days for busy pages and weeks for rarely crawled ones. You can request indexing in Search Console's URL Inspection tool for important pages, then recheck the Google-selected canonical later.

Should I use canonical tags for pages translated into Hindi or other languages?

No. Translated pages are not duplicates, because the content is in a different language. Each language version should have a self-referencing canonical and use hreflang annotations to show Google which pages are alternate language versions of each other. Pointing a Hindi page's canonical to the English page can remove the Hindi page from search.

Want an expert to fix this for you?

Subrat Patnaik and the TechnoSubrat team fix technical SEO, speed and content issues and manage SEO every month for businesses across India.

TechnoSubrat
Subrat Patnaik · SEO consultant & founder of TechnoSubrat

Subrat helps businesses across India rank higher on Google and appear in AI search with technical fixes, focused content and clear reporting. More about Subrat · technosubrat.in

Related guides

Chat with support