Skip to content
Nazmul Nikhil
Menu

Document Does Not Have a Valid rel=canonical (PageSpeed Insights)

PageSpeed flags canonicals that are relative, conflicting, point to another domain or always to the home page. Here's how to set them correctly.

Nazmul Nikhil

By

Head of SEO & Assistant Manager, Digital Marketing at Notionhive

Published 1 min read
Document Does Not Have a Valid rel=canonical (PageSpeed Insights)
Photo: Alexandr Popadin on Unsplash

In short

A canonical tells search engines which URL is the main version of a page. PageSpeed flags canonicals that are invalid or risky: more than one canonical tag, a relative or malformed URL, a URL on another domain (unless intended), or every page pointing to the home page. Use one absolute, self-referencing canonical on each indexable page, unless it's a true duplicate.

In passed form: "Document has a valid rel=canonical."

<link rel="canonical" href="https://example.com/services/seo-audit/">

Common causes

  • Two plugins each adding a canonical.

  • A theme hardcoding the home page as canonical.

  • Single-page apps leaving the first page's canonical in place after navigation (prerender each route instead).

This guide isn't affiliated with or endorsed by Google.

Sources and references

TAGSPageSpeed InsightsDocument does not have a valid rel=canonicalCanonical lighthouseInvalid canonical url
Nazmul Nikhil

About the author

Nazmul Nikhil

Head of SEO & Assistant Manager, Digital Marketing at Notionhive

SEO and AI search consultant in Dhaka, Bangladesh, helping small and mid-size businesses in the USA, UK, Australia and Canada.

Need help with this?

Get it fixed with Technical SEO

I find the issues that cost you traffic and fix them, starting with the pages that matter most.

Keep reading

Related articles

All Page Speed & Core Web Vitals posts →

Get the next guide in your inbox

One email when a new SEO or AI search guide goes live.

Ready to grow?

Get a free audit of your website, or book a 30-minute call to talk through your goals.

Nazmul Hasan

Talk to Nazmul directly

Reply within 24h

WhatsApp +880 1682835118
nazmulnikhil@gmail.com