Canonical tag: what rel=canonical does and how to get it right

Canonical tag: what rel=canonical does and how to get it right

SEOOctober 6, 2026
By Antonio Fernandez

TL;DR

  • Google's documentation ranks redirects and rel=canonical as strong canonicalisation signals and sitemap inclusion as a weak one.
  • Google only reads rel=canonical in the head of a page; non-HTML files such as PDFs can use a rel=canonical HTTP header instead.
  • Google retired the Search Console URL Parameters tool in 2022 and said its crawlers would learn to handle parameters automatically; canonicals and consistent internal links still state your preferred URL.
  • Google advises against canonicalising paginated pages to page 1, against using noindex or robots.txt to choose a canonical, and against pointing a Thai page's canonical at its English version.
  • For indexed URLs in a verified property, Search Console's URL Inspection tool shows both the user-declared canonical and the Google-selected canonical.

A canonical tag is a line of HTML, link rel="canonical", that tells Google which URL you consider the main version of a page when the same or very similar content is reachable at more than one address. Google treats it as a strong signal rather than a command, combines it with other signals such as redirects, internal links and sitemaps, and then picks the canonical URL it will show in search results.

This guide covers what the canonical tag actually does, when to use a self-referencing canonical, how it handles duplicate URLs and parameters, how it compares with a 301 redirect and noindex, the errors that cause Google to ignore it, and how to check what Google has chosen.

What rel=canonical does

Many sites serve the same content at several URLs without anyone deciding to. A product can be reached through two category paths. A page can load with and without a trailing slash, over HTTP and HTTPS, with and without "www", or with tracking parameters such as ?utm_source=line appended. To a crawler, each of those is a separate URL.

When Google finds a group of pages with duplicate or near-identical content, it chooses one as the canonical. That URL is the one Google crawls most regularly and the one it usually shows in results; the others are treated as duplicates and crawled less often. Google's documentation lists several reasons to declare your preference instead of leaving the choice to Google: to say which URL you want people to see in results, to consolidate signals such as links from duplicate URLs onto one page, to make metrics for a single piece of content easier to read, and to avoid spending crawl time on duplicates.

The canonical tag is the most common way to state that preference. It lives in the head of the HTML document and is a link element whose rel attribute is set to "canonical" and whose href attribute holds the preferred address, for example https://www.example.com/shoes/running/. Every duplicate URL in the group carries the same tag pointing at the one preferred URL.

A hint, not a directive

Google's documentation describes the canonical tag as a strong signal, alongside redirects, which are also a strong signal, and sitemap inclusion, which is a weak one. Google also considers whether a URL uses HTTPS, how the site links internally, and other factors. If your signals agree, Google normally follows your choice. If they disagree, for example the tag points to URL A but every internal link and the sitemap point to URL B, Google may choose B. That is why canonical problems are usually consistency problems.

Other ways to declare a canonical

The HTML tag only works for HTML pages. For files such as PDFs, Google supports a rel="canonical" HTTP response header that does the same job. Listing only canonical URLs in your XML sitemap is a third, weaker method. Redirects are the strongest way to make a URL the canonical, but they also stop visitors from seeing the old URL, which is not always what you want. Google advises against using more than one method to point at different canonicals for the same page, because the signals then contradict each other.

Self-referencing canonicals

A self-referencing canonical is a canonical tag on a page that points to that page's own URL. Google's canonicalization best practices recommend including one, and it is a sensible default for most templates for a practical reason: it pins down the clean version of the URL. If someone links to your page with a tracking parameter or an odd capitalisation, the copy Google crawls still states which address is the real one.

Two details make self-referencing canonicals work properly:

  • Use the absolute URL. Google supports relative paths but recommends absolute URLs, including the protocol and host. A relative path written incorrectly, or resolved against the wrong base, can point the whole site at URLs that do not exist.
  • Generate the clean URL, not the requested one. A template that copies the current request URL into the canonical tag will happily output ?utm_source=line or ?sort=price as the canonical. The tag should be built from the page's stored, preferred address.

Duplicate URLs and parameters

The most common source of duplicates is URL parameters. Some parameters change the content meaningfully, such as a page number or a product ID. Others only track or reorder it, such as campaign tags, session IDs, sort orders or view options. Pages that differ only by tracking, sort or view parameters are good candidates for a canonical tag pointing at the parameter-free version.

Google retired the URL Parameters tool in Search Console in 2022, so there is no longer a setting there to tell Google how to treat each parameter. When it announced the change, Google said its crawlers would learn how to deal with parameters automatically. Canonical tags, consistent internal links, and keeping parameter URLs out of the sitemap remain the ways to state which version you prefer.

Typical duplicate patterns worth checking on any site:

  • HTTP and HTTPS versions of the same page. Google generally prefers the HTTPS version, and a site-wide 301 to HTTPS is the cleanest fix.
  • "www" and non-"www" hosts. Pick one and redirect the other.
  • Trailing slash and no trailing slash. Pick one pattern, redirect the other, and make canonicals and internal links use it.
  • Products listed in more than one category, producing paths such as /men/shoes/model-x/ and /sale/model-x/. A canonical to one product URL consolidates them.
  • Printer-friendly or AMP-style alternate versions of an article.
  • Filtered or sorted category pages. Sort orders usually canonicalise to the default; filters that create a genuinely useful, distinct page may deserve their own canonical.

Pagination is a special case

Pointing page 2, 3 and 4 of a category at page 1 is a common mistake. Google's guidance on pagination says not to use the first page as the canonical for the series; each page should have its own canonical URL, because each lists different items. Canonicalising the whole series to page 1 can stop Google from discovering the products on later pages.

Language versions are not duplicates of each other

An English page and its Thai translation are different content, not duplicates. Each language version should carry a canonical pointing to itself, with hreflang annotations connecting the versions. Canonicalising the Thai page to the English page tells Google the Thai page is just a copy, which can keep it out of Thai results. Google's guidance is to pick a canonical in the same language, or the best substitute language if a same-language version does not exist.

Canonical vs 301 redirect vs noindex

These three tools are often confused because all of them influence which URL appears in results. They do different jobs, summarised in the table below.

Canonical vs 301 redirect vs noindex
MethodWhat it doesUse it when
rel=canonicalKeeps both URLs reachable and signals which one Google should index and showDuplicates must stay accessible, such as tracking parameters, sort orders or multiple category paths
301 redirectSends users and crawlers from the old URL to the new one; a strong canonical signalThe old URL should no longer be used, such as after a migration, an HTTPS move or a merged page
noindexKeeps the page out of the index entirely; it does not pass the page's role to another URLThe page should not appear in search at all, such as internal search results or thank-you pages

The key difference between canonical and noindex is that noindex removes a page from search, while a canonical asks Google to show a different, preferred URL in its place. Google specifically recommends against using noindex to choose a canonical within a site, because it blocks the page completely instead of consolidating it. Combining the two on one page, a noindex plus a canonical to another URL, sends mixed signals and is best avoided.

Two other tools are sometimes misused for canonicalisation. Blocking a duplicate URL in robots.txt stops Google from crawling it, which also stops Google from seeing its canonical tag, so the duplicate can still be indexed from links alone. The URL removal tool in Search Console hides URLs temporarily and is not a canonicalisation method. Google advises against both for this purpose.

Common canonical tag errors

Pointing to a URL that does not return 200

A canonical should point to a live, indexable page. A target that returns a 404, a redirect, or carries a noindex tag gives Google contradictory instructions. After site migrations, it is common to find canonicals that still point at old URLs that now redirect.

Multiple canonical tags on one page

Themes, plugins and tag managers can each add a canonical tag, leaving two or more with different values in the same page. When the declared canonicals conflict, Google may ignore them and decide on its own. View the page source and search for "canonical" to confirm there is exactly one.

Canonical placed outside the head

Google only reads rel="canonical" in the head of the document. A tag that ends up in the body, for example because invalid markup closes the head early, is ignored. An unexpected element high in the head, such as a stray iframe or an unclosed tag, can cause this.

JavaScript that changes the canonical

If the server sends one canonical and JavaScript later rewrites it to a different URL, Google may see either value. The safest approach is to set the canonical in the HTML the server returns and keep JavaScript from altering it. If a JavaScript framework must set it, make sure the rendered value matches the intended URL.

Canonicalising everything to the homepage

A misconfigured plugin or template sometimes sets every page's canonical to the homepage. That tells Google every page is a duplicate of the homepage, and the other pages can drop out of search results. This is often spotted when the Page indexing report suddenly shows many alternate pages.

Mismatched protocol, host or slash

A canonical that uses HTTP when the site runs on HTTPS, or a non-"www" host when the site uses "www", or a different trailing slash pattern, sends Google toward a URL that only redirects. Canonicals, internal links, redirects and the sitemap should all agree on one exact URL format.

Canonicalising pages that are not really duplicates

Canonical tags are meant for duplicate or near-duplicate content. Pointing a page about one product at a page about a different product, or a detailed article at a short summary, asks Google to treat different content as the same. Google may ignore it, or, if it follows it, the distinct page loses its own chance to rank.

How to check canonicals

Checking happens at three levels: what the page declares, what Google has chosen, and whether the site is consistent.

  1. Read the source. Open the page, view the source (not the inspector, which shows the rendered DOM), and search for "canonical". Confirm there is one tag, inside the head, with an absolute URL that returns 200.
  2. Use the URL Inspection tool in Search Console. For an indexed URL it shows the "User-declared canonical" and the "Google-selected canonical" (the live test cannot show which URL Google will select). If they differ, Google has decided your signals point elsewhere, and the inspection result helps you see which URL it preferred.
  3. Review the Page indexing report. Statuses such as "Duplicate without user-selected canonical", "Duplicate, Google chose different canonical than user" and "Alternate page with proper canonical tag" show where canonicalisation is happening across the site. The last one is usually expected and healthy; the first two are worth investigating.
  4. Crawl the site. A site crawler can list every page's canonical, flag canonicals pointing at redirects or errors, and find pages with more than one canonical tag.
  5. Compare with the sitemap and internal links. The sitemap should list only canonical URLs, and internal links should point to canonical URLs directly rather than to duplicates that canonicalise elsewhere.

Canonical checks are a standard part of a technical SEO audit, since a single template error can affect thousands of URLs at once.

What this means for Thai marketers

Several canonical issues show up often on sites built for the Thai market.

Bilingual sites are the first. Thai and English versions are frequently built on plugins or frameworks that set canonicals automatically, and a misconfiguration can point the Thai pages at their English equivalents. Check a sample of Thai URLs in URL Inspection to confirm each one is its own canonical and is connected to the English version through hreflang.

Thai URLs are the second. A Thai slug appears in the browser as Thai script but is sent as percent-encoded characters. Both forms identify the same URL, but templates and plugins can output them inconsistently. It is good practice to use one form consistently across canonicals, internal links and the sitemap, so the signals line up cleanly.

Tracking parameters are the third. Thai brands often share links through LINE, Facebook and other social channels with campaign parameters attached. Those parameter URLs can be crawled if they are linked publicly, and a correct self-referencing canonical on every page keeps them from competing with the clean URL.

Marketplace and e-commerce catalogues are the fourth. Stores that list the same product in several categories, or in several variants with near-identical descriptions, need a deliberate canonical plan. For businesses planning organic growth in this market, the SEO Thailand page explains how RA approaches technical SEO for bilingual sites, and stores can find platform-specific help on the e-commerce SEO page.

Canonical tag FAQ

What is a canonical tag in SEO?

A canonical tag is an HTML element, link rel="canonical", placed in the head of a page to tell search engines which URL is the preferred version when the same content exists at several URLs. Google treats it as a strong signal and usually indexes and shows the declared URL when other signals agree.

Does every page need a self-referencing canonical tag?

It is not strictly required, but Google's documentation recommends adding a self-referencing canonical as a best practice. It states the clean URL even when the page is reached with tracking parameters or other variations, which reduces the chance of duplicates being indexed.

Should I use a canonical tag or a 301 redirect?

Use a 301 redirect when the old URL should no longer be used, and a canonical tag when both URLs need to stay accessible. Redirects suit migrations and merged pages; canonicals suit tracking parameters, sort orders and products listed in several categories.

Why did Google choose a different canonical than mine?

Google picks a different canonical when other signals outweigh your tag, such as internal links, redirects, the sitemap or HTTPS pointing at another URL, or when the pages are not actually duplicates. The URL Inspection tool shows both the declared and the Google-selected canonical so you can see which URL won and align the signals.

Can a canonical tag point to another domain?

Yes, Google supports cross-domain canonical tags, so a page on one domain can declare a URL on another domain as its canonical. The same rules apply: the content should be a duplicate or near-duplicate, and the target should be a live, indexable page.

Getting canonicals right

Canonical tags are a small line of code with site-wide consequences. Most problems come from templates and plugins that output conflicting signals, and they are usually fixed once, in one place, rather than page by page. If Search Console is reporting duplicates you did not expect, or Google keeps choosing URLs you did not intend, the technical SEO audit service checks canonicals, redirects, sitemaps and internal links together, and RA's SEO services team can carry the fixes through to the live site.

Antonio Fernandez

Antonio Fernandez

Founder and CEO of Relevant Audience. With over 15 years of experience in digital marketing strategy, he leads teams across southeast Asia in delivering exceptional results for clients through performance-focused digital solutions.

Share to:
Copy link:

Read us often? Add Relevant Audience as a preferred source so our articles surface more in your Google results.