How to Install you Google AMP pages by alphapages.

About technical documentation most of the hard work is on our side we will help you make sure you are up and running.

There are 3 options in implementing AMP pages.  There is zero SEO benefit, however there is a branding benefit to have the name of your site in the top bar. Outlined below is how implement our AMP pages from easiest to hardest:

Option 1) Link amp-rel only

For each page using Google AMP replace the relative path of you link path below and  place the link rel DOM element in the head section of your page
For example
https://www.example.com/mobile-forms-apps/23185-Oil-Change-Work-Order
would have the following in the head section:

<link rel=”amphtml” href=”https://s3-us-west-1.amazonaws.com/amp.example.com/mobile-forms-apps/23185-Oil-Change-Work-Order”>

And Google’s next crawl your page will be cached and using AMP

 

Option 2) Use a subdomain with link rel

create the CNAME “amp” in your DNS settings and then point your CNAME to  https://s3-us-west-1.amazonaws.com/amp.example.com
then do Option 1 with simply:

<link rel=”amphtml” href=”https://amp.example.com/$”>

Option 3) reverse proxy subdirectory

similar to option 2 a reverse proxy would point to an external resource for a subdirectory path.  This can be accomplished in most webservers.  A common webserver nginx can accomplish this with the following code:

location ^~ /amp {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Host $host;
proxy_pass https://s3-us-west-1.amazonaws.com/amp.example.com/;
}
then once again place the link rel with the current relative path:

<link rel=”amphtml” href=”https://www.example.com/amp/$”>

 

Leave a Reply

Your email address will not be published. Required fields are marked *