{"id":17433,"date":"2020-06-02T11:52:56","date_gmt":"2020-06-02T11:52:56","guid":{"rendered":"https:\/\/ampforwp.com\/tutorials\/?post_type=ht_kb&#038;p=17433"},"modified":"2021-01-07T05:54:01","modified_gmt":"2021-01-07T05:54:01","slug":"guide-to-optimize-amp-for-google-pagespeed-insights","status":"publish","type":"ht_kb","link":"https:\/\/ampforwp.com\/tutorials\/article\/guide-to-optimize-amp-for-google-pagespeed-insights\/","title":{"rendered":"Guide to Optimize AMP for Google PageSpeed insights"},"content":{"rendered":"\n<p>In this tutorial, we will guide you to optimize AMP for Google PageSpeed insights by showing you some of the most common issues along with ways to solve them.<\/p>\n\n\n\n<p>Here is a list of Google PageSpeed insights most Common problems <\/p>\n\n\n\n<ol><li><a href=\"https:\/\/ampforwp.com\/tutorials\/article\/guide-to-optimize-amp-for-google-pagespeed-insights\/#1-remove-unused-javascript-that-has-amp-urls\">Remove Unused Javascript: That has AMP Url&#8217;s <\/a><\/li><li><a href=\"https:\/\/ampforwp.com\/tutorials\/article\/guide-to-optimize-amp-for-google-pagespeed-insights\/#2-eliminate-render-blocking-resources-css-all-cssuse-fontawesome-com\">Eliminate render-blocking resources: \u2026css\/all.css(use.fontawesome.com)<\/a><\/li><\/ol>\n\n\n\n<h4>1. Remove Unused Javascript: That has AMP Url&#8217;s <\/h4>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" loading=\"lazy\" width=\"802\" height=\"433\" src=\"https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/14.png\" alt=\"\" class=\"wp-image-17440\" srcset=\"https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/14.png 802w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/14-300x162.png 300w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/14-768x415.png 768w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/14-50x27.png 50w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/14-60x32.png 60w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/14-100x54.png 100w\" sizes=\"(max-width: 802px) 100vw, 802px\" \/><\/figure>\n\n\n\n<ol><li>Remove unused JavaScript \u2013 Usually, this is not a problem but this time, it has AMP scripts in it. Recently Google has changed the ads to AMP4Ads, now those \u201cunused\u201d URLs are actually getting loaded in the iframe. So that is also being counted as unused, which should not be the case actually this thing is confusing a lot of people. In reality, the script isn\u2019t loading, so there is no performance issue or slow down in speed as the report might suggest.<\/li><li>Eliminate render-blocking resources \u2013 Font awesome CSS is loading, to solve this, use CSS Icons from\u00a0<a href=\"https:\/\/take.ms\/hiVy7\">https:\/\/take.ms\/hiVy7<\/a><\/li><\/ol>\n\n\n\n<h4>2. Eliminate render-blocking resources: \u2026css\/all.css(use.fontawesome.com) <\/h4>\n\n\n\n<p>The goal is to reduce the impact of these render-blocking URLs by inlining critical resources, deferring non-critical resources, and removing anything unused.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" loading=\"lazy\" width=\"719\" height=\"390\" src=\"https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/15.png\" alt=\"\" class=\"wp-image-17439\" srcset=\"https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/15.png 719w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/15-300x163.png 300w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/15-50x27.png 50w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/15-60x33.png 60w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/15-100x54.png 100w\" sizes=\"(max-width: 719px) 100vw, 719px\" \/><\/figure>\n\n\n\n<p>Font Awesome CSS is loading, to solve this, use CSS Icons from AMP settings for this follow the below screenshot.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" loading=\"lazy\" width=\"1024\" height=\"388\" src=\"https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/16-1024x388.png\" alt=\"\" class=\"wp-image-17442\" srcset=\"https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/16-1024x388.png 1024w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/16-300x114.png 300w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/16-768x291.png 768w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/16-50x19.png 50w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/16-60x23.png 60w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/16-100x38.png 100w, https:\/\/ampforwp.com\/tutorials\/wp-content\/uploads\/2020\/06\/16.png 1224w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p><strong>That\u2019s it for this tutorial!<\/strong><\/p>\n\n\n\n<p>We hope it helped you. If you have any feedback or questions, then please share them in the comments section below.<\/p>\n<div id=\"div-1\" class=\"hkb-feedback\">\n\t\t\t<strong class=\"ht-mobile-exit__title\">Ask your Questions Directly!<\/strong><br>\n\t\t\t<div class=\"hkb_widget_exit__content\" style=\"font-size: 14px;\">If you can't find the solutions in this article, then just ask us in the comments and we will answer it for you!<\/div>\n\t\t\t<a href=\"https:\/\/ampforwp.com\/support\/#contact\" id=\"button\" target=\"_blank\" rel=\"noopener noreferrer\"><button>Yes, I have a Question<\/button><\/a>\n\t\t<\/div>","protected":false},"excerpt":{"rendered":"<p>In this tutorial, we will guide you to optimize AMP for Google PageSpeed insights by showing you some of the most common issues along with ways to solve them. Here is a list of Google PageSpeed insights most Common problems Remove Unused Javascript: That has AMP Url&#8217;s Eliminate render-blocking resources:&#8230;<\/p>\n","protected":false},"author":18,"comment_status":"open","ping_status":"closed","template":"","format":"standard","meta":[],"ht-kb-category":[],"ht-kb-tag":[],"_links":{"self":[{"href":"https:\/\/ampforwp.com\/tutorials\/wp-json\/wp\/v2\/ht-kb\/17433"}],"collection":[{"href":"https:\/\/ampforwp.com\/tutorials\/wp-json\/wp\/v2\/ht-kb"}],"about":[{"href":"https:\/\/ampforwp.com\/tutorials\/wp-json\/wp\/v2\/types\/ht_kb"}],"author":[{"embeddable":true,"href":"https:\/\/ampforwp.com\/tutorials\/wp-json\/wp\/v2\/users\/18"}],"replies":[{"embeddable":true,"href":"https:\/\/ampforwp.com\/tutorials\/wp-json\/wp\/v2\/comments?post=17433"}],"version-history":[{"count":8,"href":"https:\/\/ampforwp.com\/tutorials\/wp-json\/wp\/v2\/ht-kb\/17433\/revisions"}],"predecessor-version":[{"id":17897,"href":"https:\/\/ampforwp.com\/tutorials\/wp-json\/wp\/v2\/ht-kb\/17433\/revisions\/17897"}],"wp:attachment":[{"href":"https:\/\/ampforwp.com\/tutorials\/wp-json\/wp\/v2\/media?parent=17433"}],"wp:term":[{"taxonomy":"ht_kb_category","embeddable":true,"href":"https:\/\/ampforwp.com\/tutorials\/wp-json\/wp\/v2\/ht-kb-category?post=17433"},{"taxonomy":"ht_kb_tag","embeddable":true,"href":"https:\/\/ampforwp.com\/tutorials\/wp-json\/wp\/v2\/ht-kb-tag?post=17433"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}