Google AMP cache url generator

The Google-AMP-Cache-URL-Generator creates a suitable URL in the AMP-Cache-Format from the normal URL of any subpage, of any website.

Build AMP cache url


http

With the generated cache URL, the AMP version of a website stored in the Google AMP cache can be called IF the corresponding page has already been indexed by Google and saved in the Google cache.


Advertisement

The AMP cache URL format


link

If possible, the Google AMP Cache creates a subdomain for all AMP pages that are on the same domain.

First, the domain of the website is converted from IDN (pony code) to UTF-8 . The cache server replaces:

  • each - (1 hyphen) through - (2 hyphens)
  • everyone . (1 point) through - (1 hyphen)
  • Example: amp-cloud.de would become
    amp--cloud-de.cdn.ampproject.org

The converted domain is the host address of the Google AMP cache URL. In the next step, the full cache URL is put together, with the following parts added to the host address:

  • an indicator that classifies the file type
    • a / c / for AMPHTML files
    • a / i / for images
    • a / r / for fonts (fonts)
  • an indicator that enables loading via TSL (https)
    • a / s / to activate
  • the original URL of the website without the HTTP scheme

Example of a URL in the Google AMP Cache URL format:


beenhere

Beispielhafte original URL:

  • https://amp-cloud.de/amp-cache-url-generator.php?test=123&abc=hallo+welt

Theoretical AMP cache url:

  • https://amp--cloud-de.cdn.ampproject.org/c/s/amp-cloud.de/amp-cache-url-generator.php?abc=hallo%2Bwelt&test=123

What is the Google AMP cache?


dns

Part of the acceleration of websites in the Google AMP format is caused by the automatic storage in the server cache of the Google search . This means that the AMP versions of a website are not loaded from the website's web server, as is usually the case, but directly from the search results of the Google search from one of the Google servers (the Google AMP cache server) , which are usually enable significantly faster loading times.

This means that Google indexes and saves a version of the AMP page on its own server, under an independent AMP cache server URL that is created according to a specific pattern. With this URL, in the AMP cache URL format , you can call up and view the current AMPHTML version that is currently stored in the AMP cache of the Google search engine. - More information about the Google AMP cache .


Advertisement