APO and AMP Pages

I originally posted this on the Cloudflare plugin support page (https://wordpress.org/support/topic/issue-with-amp-plugin-2/) but it does not look like Cloudfare responds to those posts.

I recently started using the AMP plugin and immediately noticed that I was not getting the full benefits of Automatic Platform Optimization.

While AMP pages were ultimately loading faster overall, “Time to First Byte” and “First Paint” were coming in double that of Non-AMP. So, not as fast as they should have been.

A presume the issue is that the AMP plugin uses ‘/?amp’ rather than ‘/amp/’ to identify pages.

My current workaround has been to set up a Cache Everything page rule for AMP pages, which has worked. However, that does not seem like the best solution.

Is there another option?

Ofc the will not watch “some random” comments on a wordpress forum. Why should they? They are not getting notified about anything there.

Yes, this makes the request dynamic.
Would you mind posting a link to an AMP site which now is slower then before?

As I stated in my original post, I set up a Cache Everything page rule for AMP pages. So, not slower now. However, if I were to turn that off (which, without a fix, I am absolutely not doing) they are slower.

The “official” AMP Plugin’s documentation states that using “/amp/” has been depreciated “to prevent ambiguity in the URL and to ensure all URLs of a site can be served as AMP”.

Looking through the Cloudflare forum, it does seem that Cloudflare initially had a hard time with “/?amp” and was initially serving non-APM versions. However, even though that one issue was fixed, it does not seem websites are getting the full benefits of the APO on AMP pages identified with “/?amp”.

Since “/?amp” seems to be what Google wants and Cloudflare interprets it as dynamic content, I’m looking for a solution.

Just set a “Cache Everything” rule to:

https://your-domain.tld/?amp*

This should activate Cache Everything to all of your AMP Links. But if you change content of a page you should wipe cache of this particular URL so it gets updated in CloudFlares Cache aswell the next time someone calls the link (per POP)

Um, as I stated, I do have AMP pages set for Cache Everything. And, the reason I have them set to Cache Everything is because there seems to be an issue with the APO and “/?amp”. I am looking for a solution that is not Cache Everything… like maybe Cloudflare making adjustments because of how Google wants to see these URLs based on the AMP plugin’s documentation.

There is no solution for AMP pages other than Cache Everything or changing URL schema for AMP pages.

2 Likes

@yevgen

Thank you for also providing a reply on the Cloudflare plugin support page.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.