Clicky

  1. Home
  2. Extension & Themes
  3. Purge AMP CDN Cache
  4. How to clear the AMP CDN Cache from Google Servers

How to clear the AMP CDN Cache from Google Servers

Purpose of Google AMP Cache

The Google AMP Cache serves cached copies of valid AMP content published to the web. Serve content directly from the Google AMP Cache to provide a fast user experience.

The Google AMP Cache automatically requests the latest version of the AMP document from its origin and serves the updated version to the next user. That means that when you load the AMP Cache URL directly, that forces the cache to update, even without the more “urgent” update ping method.

Purge AMP CDN Cache

By using update-cache request it will update and remove the content from the Google AMP Cache. The content is updated within its max-age and crawl the fresh cache.

The update-cache the request requires the domain owner to sign the requests with an RSA key and to serve the matching public key from a standard URL on the origin domain.

How to Generate the RSA key

The OpenSSL project provides command-line tools to generate and manage asymmetric RSA keys. You can also generate RSA keys and manage them programmatically through the OpenSSL library, or an equivalent crypto API (node-crypto, NSS, or GnuTLS).

Generate a pair of RSA keys in the textual PEM format like this:

Post the public key on the domain to be refreshed at the following location:

The URL must be HTTPS. The key must be publicly accessible by Google.

Here are the steps :

  1. Download and Install Purge AMP CDN Cache extension.
  2. Upload and Activate
  3. Done! The Purge AMP CDN Cache will be visible on the AMP version of your site.

For more details how to upload extension click on this link  Upload and Install.

Note: Copy the private key and paste into entering private key section like below the screenshot.

Step 1: First go to WordPress Admin Area -> AMP option panel -> click on Purge AMP CDN Cache.

Step 2: Enter private key in this section.

Step 3: Click on the “submit” button.

How to Purge AMP CDN Cache in view Posts/Pages

Where you want to update the cache select posts/pages. Only it will be displayed on view posts/pages, For example, I am using posts like below the screenshot.

Step 1: Go to WordPress dashboard -> click on posts -> left-hand side Update AMP cache option is appear only on view post click on the “clear now” button like below the screenshot.

Step 2: Once you clear cache Green color check mark will be displayed on the left-hand side like below the screenshot.

That’s it for this tutorial!

We hope it helped you. If you have any feedback or questions, then please share them in the comments section below.

Ask your Questions Directly!
If you can't find the solutions in this article, then just ask us in the comments and we will answer it for you!
Updated on July 3, 2019

Was this article helpful?

Need Support?
Can’t find the answer you’re looking for? Don’t worry we’re here to help!
Contact Support

Comments

  1. Hi,

    Thank you for this amazing plugin, but I have an issue: I can’t see this option on “Pages”. Is there another option to clear the AMP cache of a page?

    Thanks,
    Mireia

    1. Hi Mireia,

      That option will be available in update AMPcache extension and that extension will be release soon.

Leave a Comment