Reputation: 131
I have a regular website that works well on mobile devices, I use a header and footer with all pages and .php extension for the pages and .html on the header and footer. A couple of weeks ago I decided to create an AMP version of my website, and decided that I would only create one AMP page with a canonical reference back to my main page - I only wanted to create 1 AMP page.
So on my non AMP page (in the header.html) I declare
<link rel="amphtml" href="https://example.com/amp/local-web-design.php" />
And on my AMP page which is not using headers and footer but is still a .php extension page I declare
<link rel="canonical" href="https://example.com/homepage.php" />
Google served up the page to mobiles a total of 5 times in three days and then subsequently decided that it did not like that I did not have all my other pages which hang off the non AMP page converted to AMP pages, including the privacy and contact page. For a start the contact page has a form which is not supported by AMP.
Google Webmaster Console shows no errors, but has the following 'info issues'
Info:Missing structured data element
Content mismatch between AMP and canonical pages
All seem to be referring to the fact that I have not created all the other additional pages & the only error listed is "a value for the image field is required".
I could create AMP pages for all the other pages, which incidentally show off our work and customers in different towns, but how then would I declare them all in the header.html with
<link rel="amphtml" ...>
as the header serves all pages for my non AMP website. Can I just use multiple link rel's?
<link rel="canonical" href="https://example.com/page1.php" />
<link rel="canonical" href="https://example.com/page2.php" />
I should also mention that if I test the AMP page with the following it passes with flying colors
https://validator.ampproject.org/#url=https://example.com/amp/local-web-design.php
Upvotes: 0
Views: 1966
Reputation: 4074
The problem seems to be that you're using 1 header for all of your pages and that header claims that all of your pages have AMPs.
Ideally you should just use a special header for the one page that has an AMP.
Upvotes: 0
Reputation: 8082
Content mismatch error can be encountered when there is a difference in content between the AMP page and its canonical web page. As stated in Search Console Help - AMP report,
The text need not be identical, but the topic should be the same, and users should be able to accomplish the same tasks on both the AMP and the canonical page.
A mismatch can also occur when a
robots.txt
file blocks significant resources on one or the other.To fix the error, you may want to do the following:
- Ensure that the AMP is referencing the correct canonical web page.
- Ensure that the general content of the AMP and canonical page are the same.
- Check that Google's view of the page is not different from the user's view of the page by using the Fetch as Google tool for both the AMP and the canonical page.
Furthermore, please note that if you've submitted a fix but the error is still being shown in the report, remember that Google crawls a page only periodically. You can wait for the scheduled regular recrawl, or you can request a recrawl using the Fetch as Google page.
Hope that helps!
Upvotes: 1