Canonical Tag Generator

Generate a rel=canonical link tag from a URL — paste the address you want treated as the master version of a page, and copy the tag into your head.

SEO Tools Free No upload Instant

Loading Canonical Tag Generator…

Your browser is preparing the tool. It runs 100% locally.

Quick Answer

Paste the URL you want search engines to treat as the canonical (master) version of a page, and the tool outputs a single rel=canonical link tag to drop into the head. Canonical tags consolidate duplicate or near-duplicate URLs onto one address, so ranking signals are not split. Use the full absolute URL — relative paths are ignored by Google. It builds live and runs entirely in your browser.

What the Canonical Tag Generator Does

Enter the address that should be the single indexed version of a page, and copy the generated link rel=canonical tag into the head. It is one tag, escaped so the markup stays valid — the tool's whole job is to format that one line correctly.

Canonical tags matter when the same content is reachable at several URLs — with and without a trailing slash, with tracking parameters, http versus https, or printer-friendly variants. The canonical points all of them at one address so Google folds them together instead of treating them as competing duplicates.

How It Works

The tool wraps your URL in a link element with rel set to canonical and href set to the address you typed, escaping any special characters. That tag tells crawlers: of all the URLs showing this content, this is the one to index and credit.

For it to work, the URL should be absolute — the full address including https and the domain — because Google ignores a relative canonical. Most pages should also carry a self-referencing canonical (pointing at their own URL), which removes any ambiguity about the preferred version.

Generation algorithm

  1. Take the URL. Read the canonical address you entered.
  2. Escape it. Convert any special characters so the attribute stays valid.
  3. Wrap it. Place it in a link element with rel canonical and href set to your URL.
  4. Output live. Show the finished tag to copy into the head; it updates as you type.

Tag it generates

link rel=canonical href=your-absolute-URL

One tag, placed in the head. Use the full absolute URL (with https and the domain); a relative path is ignored by Google.

Technical Details

Inputthe canonical URL
Outputone link rel=canonical tag
Placementin the head (or sent as an HTTP Link header)
URL formabsolute (https and domain)
Escapingspecial characters become entities
Where it runsIn your browser — nothing uploaded

Standards & references

  • rel=canonical — the link relation that names the preferred URL among duplicates; Google consolidates ranking signals onto it.
  • Absolute URLs — the canonical href must be a full absolute URL — Google does not recognise a relative path here.
  • Self-referencing canonical — most pages should point a canonical at their own URL, making the preferred version explicit.

Accuracy & Limitations

It does not validate the URL. Make sure it is the full absolute address (https and your domain) and that it actually resolves — a canonical pointing at a broken or redirecting URL can hide the page you meant to rank.

One canonical per page. Two conflicting canonical tags, or a canonical that fights your sitemap or internal links, confuses Google — it may pick a different URL than you intended. Keep your signals consistent.

A canonical is a strong hint, not a command. Google usually honours it but can choose a different canonical if your other signals disagree. It also is not a redirect — visitors still load whatever URL they clicked.

Do not use it to canonicalise genuinely different pages onto one. That can drop the others from the index. Use it only for duplicates or close variants of the same content.

This tool makes the tag; it does not add it to your pages. Paste it into each page's head, or serve it via the Link HTTP header for non-HTML files such as PDFs.

Real-World Use Cases

Trailing-slash and parameter variants

Point /page and /page/?utm=... at one clean URL so they do not compete.

Self-referencing canonicals

Give each page a canonical to its own URL as a clear default.

Syndicated content

When the same article lives on several URLs, name the original as canonical.

http, https and www

Consolidate protocol and subdomain variants onto the preferred address.

When to use it — and when not to

Good for

  • Pointing duplicate URLs at one master version
  • Self-referencing canonicals on normal pages
  • Parameter, trailing-slash and protocol variants
  • A correctly-formatted single tag to paste

Not the best choice for

  • Redirecting users (it is not a redirect)
  • Canonicalising different pages onto one
  • Blocking a page from search (use noindex)
  • Checking that the URL resolves

Want visitors actually moved to one URL? Use a 301 redirect. Want a page kept out of search? Use a robots noindex tag, not a canonical.

Frequently Asked Questions

What does a canonical tag do?
It names the preferred URL when the same content sits at several addresses, so Google indexes and credits that one and folds the duplicates into it.
Should the URL be absolute or relative?
Absolute — the full address with https and your domain. Google ignores a relative canonical.
What is a self-referencing canonical?
A canonical that points at the page's own URL. It is a recommended default that removes ambiguity about the preferred version.
Is a canonical the same as a redirect?
No. A redirect sends visitors to another URL; a canonical just tells crawlers which version to index. Visitors still load the page they clicked.
Will Google always obey it?
Usually, but it is a hint, not a rule. If your sitemap, internal links or other signals disagree, Google may pick a different canonical.
Can I canonicalise two different pages onto one?
You can, but you should not — it can drop the others from search. Use it only for duplicates or close variants.
Where does the tag go?
In the head of the page. For non-HTML files like PDFs, you can send the same thing as a Link HTTP header instead.
How many canonicals per page?
Exactly one. Multiple or conflicting canonical tags confuse crawlers and may be ignored.
Does it stop duplicate-content penalties?
There is no specific duplicate-content penalty, but a canonical helps Google consolidate signals instead of splitting them across URLs, which is good for ranking.
Does the tool check my URL works?
No. It only formats the tag. Make sure the URL is correct and resolves before you rely on it.
Should the canonical match my sitemap URL?
Yes. Keep canonical, sitemap and internal links all pointing at the same preferred URL so your signals agree.
Is anything uploaded?
No. The tag is built in your browser as you type.

References

Formats one rel=canonical tag from your URL; it reminds you to use an absolute, self-referencing address and is clear that a canonical is a crawler hint, not a redirect.

PopularHot

Meta Tag Generator

Meta Tag Generator that outputs clean, copy-ready code for better rankings.

SEOOpen Tool
Popular

Keyword Density Checker

Keyword Density Checker online — accurate, standards-compliant and free for SEO work.

SEOOpen Tool
Popular

UTM Link Builder

UTM Link Builder online — accurate, standards-compliant and free for SEO work.

SEOOpen Tool
Trending

Open Graph Generator

Open Graph Generator that outputs clean, copy-ready code for better rankings.

SEOOpen Tool
Trending

SERP Snippet Preview

SERP Snippet Preview online — accurate, standards-compliant and free for SEO work.

SEOOpen Tool
Editor's Pick

Schema Markup Generator

Schema Markup Generator online — accurate, standards-compliant and free for SEO work.

SEOOpen Tool

Ready to try the Canonical Tag Generator?

It is free, private and runs entirely in your browser — no sign-up, no uploads, no limits.