Google's AMP is a gilded cage


AMP is Google's attempt to re-fight the transcoding wars of the early 2000s.

It is actively dangerous to the web ecosystem, helps disseminate propaganda, and is disliked by many users.

If, like me, you made the mistake of trying out AMP on your website - you're in a tricky position if you try to remove it. Google doesn't like anything leaving its clutches.

After a few weeks of AMP, I decided that it wasn't suitable for me. So I uninstalled the WordPress plugin. That's when the problems started.

When someone searches for my site on mobile, they still get presented with an AMP link:

AMP pages showing in search results
Which leads to an error page:

An AMP error page

No matter, they can click through to the real page, right?

A 404 error page

No. The /amp page doesn't exist and causes a 404 error. Google could use the canonical URl to serve the original page - but that's too much like hard work for them.

So, how do you fix this? Thanks to Google's legendary lack of support and pathological aversion to writing clear, updated documentation - it's really hard to find a straight answer.

You would have thought that after a few days of getting AMP errors, Google would take the hint and stop serving the content, right? Sadly no.

There is one scrap of information which might give you some hope:

Use the "update-ping" mechanism to permanently remove content from the Google AMP Cache after the content has been removed from its origin. For example, to purge content formerly served at https://cdn.ampproject.org/i/s/example.com/favicon.ico, send an update ping request to:

https://cdn.ampproject.org/update-ping/i/s/example.com/favicon.ico.

Cached content that no longer exists will eventually get removed from the cache; it's just faster to use "update-ping".
Google's Remove AMP content "documentation"

If I'm reading this right, I have to send a ping for every page on my site.

Something like

https://cdn.ampproject.org/update-ping/c/s/shkspr.mobi/blog/2015/09/i3-electric-car-review/amp

For a few thousand pages. That's... bonkers! And, best of all, it doesn't work.

I chose a page, sent the ping, waited a few hours and... nothing! The AMP links still showed up in Google's results.

What's the solution? At this point you only have two options:

  1. Accept Google's benevolent intentions and reinstall AMP.
  2. Wait and hope.

I should have learned my lessons from my last interaction with Google. Oh well, fool me once...


Share this post on…

47 thoughts on “Google's AMP is a gilded cage”

  1. Neil says:

    A mobi domain, indeed a blast from the past 😉
    How about 301 redirects?

    Reply
    1. Terence Eden says:

      Ha! And now look at all the weird domains we have 🙂

      I've got a few thousand pages here. Redirecting them all correctly isn't a task I have time for.

      Reply
      1. masterk999 says:

        The Redirection plugin for WordPress allows wildcards. You can build a single rule that will redirect all AMP page links to the correct page.

        Reply
        1. Terence Eden says:

          Yet another plugin to configure, test, maintain. I'll take a look - but this really ought to be fixed by Google.

          Reply
          1. says:

            You can do it easily in your .htaccess or the index.php of your site. Rewrite everything with /amp to the same URL without /amp, it's one line in .htaccess.

            Reply
  2. foo says:

    A quick fix on your server is to redirect all the amp pages to the original post.

    And seems fairly plausible that if Google follows such redirects it will attempt to modify their index and may fix the links served as search results. Think it's worth trying.

    Reply
    1. Terence Eden says:

      That's nice in theory - but I've got a few thousand pages on here. A bit tedious to set them *all* to redirect to the correct logation.

      Reply
      1. Tomasz says:

        With proper routing scheme you could have a few million, and it would still cost you a few lines of code.
        Crawling and indexing websites is not something that is done few milliseconds after you push a new content. But you still have a very powerful tool to tell Google "hey guys, I did major change and need my website reindexed". You do this with webmaster tools.

        Now it's not a matter of using Google's amp. It's how your website is structured at the moment it is remembered by indexer. You could have replaced WordPress with something else and you would still face the same problem. You see, you can modify that 404 URL to cached:shkspr.mobi/... and see what the content was the last time that site was indexed.

        First of your problems is that you did not take care of redirecting your website.

        Second is that you likely have very long caching settings on each of your pages.

        Third is that you probably never used webmaster tools.

        Go check the third option. Will save you some trouble next time you do a major change.

        Reply
        1. Terence Eden says:

          Hi Tomasz,

          Thanks for the comment.

          1. I disagree. I provided all AMP pages with a canonical URl as per the AMP specification. When Google noticed a problem, it should have handled the redirect gracefully.
          2. I don't. I use a CDN to cache the pages - but only for a few hours.
          3. I did use webmaster tools. I requested a full re-crawl. That happened fairly quickly, but didn't stop the problems.

          Reply
          1. The issue is that once you removed the amp page, the canonical from the amp URL is inherently no longer there. As others are saying a rewrite rule in your .htaccesa file to remove /amp from the end of the URL via 301 redirect is the way to go.

            RewriteRule ^/?(.*)/amp/?$ /$1 [R=301,L]

            That should do the trick as the amp plugin adds

            Reply
  3. Someone says:

    You can use apache rewrite rules to redirect your users to a different page. You don't need to update every single page by hand, it's just a one-off thing.

    Reply
      1. Adam says:

        Google mod_rewrite (I'm on a tablet right nursing a hangover or I'd do it for you).

        You can use regular expressions and references to do something like:

        RewriteRule /(.*)/amp /$1 [R=301]

        Full disclosure: still haven't used AMP so I have no idea what the URLs look like.

        Reply
        1. says:

          A big thanks for the code guys,it worked for us. In Redirect plugin add (.*)/amp/$ in source url and $1 in target url. Now our amp pages are getting redirected to the original url.

          Reply
      2. claire says:

        You're running WordPress so it should be trivial to add a single mod_rewrite rule that strips /amp/ off the end of URLs to your htaccess.

        Reply
        1. Terence Eden says:

          If it is trivial, please let me me know what people need to do to fix it.

          Reply
  4. Anon says:

    One line of code in the shared template / layout page can do that dynamically. Why would you have to implement manually?

    Reply
  5. Cole says:

    What was it that made you want to stop using AMP in the first place? All I know is that it speeds up mobile, so I'm kind of ignorant on the subject.

    Reply
  6. says:

    Terence, if all your "amped" versions of the articles were addressable with that added "/amp/" url fragment and are at their "correct" address without the "/amp/"', the the following rewriteRule in your .htaccess file should take care of the hits from googles result:

    RewriteRule (.*)/amp/$ $1 [R=301,L]

    Depending on how your blog is set up the .htaccess file is in your root directory or the 'blog' directory, it is where the rewriteRules for wordpress' own urlrewriting live. this rule should be typed above the wordpress rules.

    Reply
  7. I assume you're using Apache and have a .htaccess file in the root, and you've got mod_rewrite on? Add this line near the top, after RewriteEngine On:

    RewriteRule ^(.*)/amp/?$ /$1 [L,R=301]

    Reply
  8. Amit Kriplani says:

    Google doesn't remove 404 pages from its index. Reason can be if your site is accidently broken do you want Google to remove all your indexed pages? Generally 301 is the best solution for removing pages from the site. 410 status code is also supposed to work for removing previously indexed pages but I haven't tested that. This is true for all pages and not only amp pages.

    Reply
        1. Terence Eden says:

          Repeating it isn't the same as proving it. Find an link from a reliable source which shows that.

          Reply
  9. says:

    Sorry that you experienced such difficulties, but I am glad you wrote this article to warn people against using AMP.

    Between responsive design and HTTP/2, there is no need for google to get involved at all. And speaking as a professional web developer, any "solution" which uses a special "mobile only" website when browsing on phones or tablets is a hack, and not a real solution at all. Mobile only versions are an ancient relic which were supposed to be eliminated by responsive design. Google really dropped the ball on this one.

    Reply
    1. Terence Eden says:

      For me, I didn't find any benefit. The real-world loading speed didn't increase dramatically. The lack of comments was annoying. It's hard to share a URl from an AMP site. It makes it look like your site is from Google. Finally, after a few weeks of use, I hadn't noticed any significant difference in visitor numbers. Overall, for a small blog like mine, I didn't see any point to it.

      Reply
  10. says:

    Man thank you so much for sharing this post. I was about try this and other AMP pluggings for my website. But now. I am definitely not. Also I would have liked to see what are cons and pros of it.

    Francisco.

    Reply
  11. Codengo says:

    Gotta say three things here. 1, this would only be a problem for an amateur web master (as you can tell by the other comments). 2, it was a Google now card in the "recommended stories for you" section that got me here. Not really relevant but I liked the irony. 3, the mobile theme needs some work, I like the concept but I think the design has room to improve.

    Finally, don't discount this 'update-ping' technique, doing it for 1000 pages is no harder than doing it for 10, once you've got the right cURL command just put it in a loop. The results may still take some time to process, the AMP servers are edge servers after all, and there are a lot of them.

    Reply
    1. Terence Eden says:

      1) there are lots of amateurs in the world. Why should they have to suffer?

      2) proving that AMP isn't that important.

      3) feel free to send a pull request. https://github.com/edent/blog-theme

      4) as I said, the update ping method doesn't work. Even if it did, which curl command will find all of the former amp pages on my site?

      Reply
  12. Suri says:

    "pathological aversion to writing clear, updated documentation" -- Quite True

    Reply
  13. says:

    Love the irony that the Google Now card that sent me here to your mobi one of your mobi pages worked flawlessly.

    Reply
  14. I'm against AMP by principle. AMP pages are hosted on Google CDN servers. If AMP use gets widespread, a chunk of the internet will then be exclusively hosted by Google. Google can then rein the internet at will. Their news aggregator already only serve AMP pages. Their search engine heavily promotes them as well. Responsive design is better since it leaves webmasters in control and you maintain a free open market for information. If we transition to an AMP world the last remnants of freedom and access to the crowds will be determined by Google. IMO the best thing we could use right now is a new distributed, decentralized open source search platform instead of Google.

    Reply
  15. PiNG says:

    I too got the Google Now Card for this, and to be honest, I doubt I'd have stumbled on your blog. I'm glad I did find it, and I can understand your frustrations.

    Several people have given advice on how to revert back, so I'll skip that. There are automated ways of handling millions of changes, so I think you really need to find a method that works for you and your situation.

    I also am very against AMP, it's not useful for smartphones, but dumbphones, sure. The real problem is the controlling factor that whereskarlo stated.

    Reply
  16. Codengo says:

    Wow, a bunch of FUD in this thread. AMP is not a Google conspiracy to censor the internet...

    Reply
    1. Hubert Łępicki says:

      Of course it's not. It's Google's conspiracy to serve even more, own ads, and cut off the competition.

      Google is advertising company, nothing more. Never forget that!

      Reply
  17. Mark says:

    Hi Man! I have the same problem! I tried with redirect but from google redirect doesn't work (only with direct link it does). You fixd it? Let me know

    Reply
  18. fatmike says:

    People, It does NOT matter what you, or your server administrator do on your end.
    Redirects won't work if the page is already cached from Google

    Reply

What links here from around this blog?

What are your reckons?

All comments are moderated and may not be published immediately. Your email address will not be published.Allowed HTML: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre> <p> <br> <img src="" alt="" title="" srcset="">