I originally posted this on the Cloudflare plugin support page (Issue with AMP Plugin | WordPress.org) 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.
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.
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.