AMP Validation Errors Example
I sent a smaller, faster version of myself ahead by cannonball, and he forgot to mention who had fired him.
The short answer
- What it is
- An AMP validation error means an AMP page lacks required markup or its link with the main page is broken. The declared AMP URL may fail, may not link back, or may have no canonical tag.
- Why it matters
- An invalid AMP page can't be served from the AMP cache and can't use AMP-only features. A broken pair also leaves search engines unsure how the two pages relate.
- How a crawler should report it
- Report a warning on the page that declares the AMP URL, with the target's status and whether its canonical points back. For the AMP page itself, list each missing required item by name.
- Live examples
/lab/amp-issues/declared/(positive)/lab/amp-issues/near-miss/(near miss)

Broken Canonical Pairs and Missing AMP Markup
AMP validation errors fall into two groups: broken links between pages and broken markup. A normal page names its AMP version with <link rel="amphtml">. The AMP page must point back with <link rel="canonical">. If either side is wrong, the pair fails. A page with no separate version can be its own AMP page, in which case its canonical points to itself.
An AMP page has strict needs. It must start with a doctype and have the ⚡ or amp attribute on its html tag. The head must include a UTF-8 charset, a viewport tag, the AMP runtime script, and the AMP boilerplate style. Custom JavaScript is limited, and some tags are banned. Errors often arrive with new ads, widgets, or CMS updates. A plugin may add a style attribute or a script that the format doesn't allow.
Browsers will still show an invalid AMP page, so visitors may notice nothing. Search engines react differently. Google will not serve an invalid page from its AMP cache or show it with AMP features. Since 2021, AMP is no longer required for Top Stories in Google Search. Many sites have dropped AMP for that reason, and some have left stale amphtml tags behind. Those tags point at pages that no longer work.
To detect errors, follow each amphtml link and record the status. Check that the target has a canonical pointing back. Test the markup with the official AMP validator, or add #development=1 to the URL and read the browser console. To fix a pair, correct the links at both ends. To fix markup, remove what the error names. If you no longer want AMP, remove the amphtml tag and 301 redirect each AMP URL to its normal page.