Skip to content

Canonical Tag Validator

Check the rel="canonical" tags in pasted HTML offline. Find missing, multiple, conflicting, relative, fragment, malformed and non-HTTP canonicals, see whether each one is absolute, and compare it with an optional current-page URL. Nothing is fetched or run.

Web & SEO Runs client-side Free to use
Jump to the tool
Share: X WhatsApp
Loading Canonical Tag Validator…

About the Canonical Tag Validator

Canonical Tag Validator reads the HTML you paste and reports on every <link rel="canonical"> tag it contains. It shows whether the canonical is in the <head>, whether there is none, one or several, whether several tags conflict, and whether each URL is absolute, relative, malformed, uses a #fragment or a scheme other than http or https.

If you also enter the current page URL, the tool tells you whether the canonical is self-referencing, differs only by a trailing slash, or points somewhere else. The HTML is parsed as inert text with the browser’s own parser, so scripts in it never run and nothing is loaded. Because it works offline, it cannot fetch pages, verify redirects, read HTTP Link headers, detect duplicate content or tell you which URL Google will pick: a canonical tag is a hint, not a command.

How to use

  1. Paste the page’s HTML source into the box (or insert the sample).
  2. Optionally enter the current page URL to compare against.
  3. Click Validate.
  4. Read the errors, warnings, notes and passes, and the table of tags found.
  5. Copy or download the report, or press Reset to start again.

Key features

  • Detects missing, multiple and conflicting canonical tags.
  • Flags canonicals placed in the <body>.
  • Checks for relative, fragment, malformed and non-http(s) URLs.
  • Resolves relative canonicals against the current URL or a <base> tag.
  • Self-reference and trailing-slash comparison with the current page URL.
  • Safe parsing: pasted HTML and scripts are never executed.
  • Copy Report, Download Report, Reset and Back.

Best practices

  • Use exactly one canonical tag per page, inside the <head>.
  • Prefer absolute https:// URLs for canonicals.
  • Point duplicates and variants at the preferred URL; give unique pages a self-referencing canonical.
  • Keep the canonical consistent with your sitemap, internal links and redirects.
  • Paste the rendered source if your canonical is added by JavaScript, because this tool reads only what you paste.

Benefits

  • Catches common canonical mistakes before you publish.
  • Clear, specific messages instead of a single score.
  • Works on staging or private pages because nothing is fetched.
  • Private: nothing is uploaded or stored.

Frequently asked questions

What does a canonical tag do?

It tells search engines which URL you prefer when several URLs show the same or very similar content. Search engines treat it as a strong hint, not a rule, so they may still choose a different URL.

Can this tool fetch my page or check redirects?

No. It works only on the HTML you paste. It cannot fetch pages, follow or verify redirects, read HTTP Link headers or check your sitemap.

Is a relative canonical URL wrong?

Relative canonicals are accepted by Google, but they are easy to get wrong, for example on staging copies or with a <base> tag. The tool warns about them and recommends a full https:// URL.

Why is a canonical in the body an error?

Google only uses rel="canonical" link tags in the <head>. Visible content placed before a tag can also end the head early, so the tag may be ignored.

What if I have two canonical tags?

If they point to different URLs, search engines are likely to ignore both. If they point to the same URL, it is not harmful but you should keep only one.

Can it tell me whether my page has duplicate content?

No. Detecting duplicate content requires comparing many pages, which this offline tool cannot do. It also cannot guarantee which URL Google selects as canonical.

Is my content uploaded or saved?

No. Everything runs in your browser. What you paste or type is not sent anywhere, no URL is fetched, and nothing is saved in browser storage. Reset clears it from the page.