Solve the tag 'amp-ad extension .js script' is missing

When implementing AMP pages, and getting the error the tag 'amp-ad extension .js script' is missing or incorrect, but required by 'amp-ad'. This will soon be an error, in Google Search Console with Google AMP ads or over advertisement network, it simply means that a specific AMP script for ads has been forgotten in the web page.
`) is included in the head of your AMP HTML document. This script is necessary for displaying ads on AMP pages and must be correctly referenced to avoid validation errors."} }] }

The tag 'amp-ad extension .js script' is missing

When implementing AMP pages, and getting the error the tag 'amp-ad extension .js script' is missing or incorrect, but required by 'amp-ad'. This will soon be an error, in Google Search Console with Google AMP ads or over advertisement network, it simply means that a specific AMP script for ads has been forgotten in the web page.

Include it and the error will be gone.

How to fix 'amp-ad extension.js script missing' error?

What is accelerated mobile pages

What does AMP mean on Google? The accelerated mobile pages, also called AMP, are a new standard for mobile browsing. An AMP version of a web page is cached by Google or another search engine, is a cached version is delivered to the client.

The display is much faster, as accelerated mobiles pages AMP must observe very strict development rules, use common libraries, and do not include many things that are usually slowing down pages loading, such as extra script, external frames, or large images.

AMP HTML project on github
Lycamobile activate Internet Accelerated mobile page AMP version

How to test AMP pages

One of the easiest way to test AMP pages, is to use the Google Search Console URL inspection and AMP testing tool.

This tool will test AMP pages, and send back any issue with the page, such as the tag 'amp-ad extension .js script' is missing or incorrect, but required by 'amp-ad'. This will soon be an error.

It will generally offer links to AMP documentation, in order to find how to solve the issue and make the website AMP ready for display in Google search network and other search engines that are able to handle AMP pages.

Google URL inspection and AMP testing tool

Accelerated mobile pages Wordpress

Master Website Creation: Enroll Now!

Transform your digital presence with our comprehensive Website Creation course – start your journey to becoming a web expert today!

Enroll Here

Transform your digital presence with our comprehensive Website Creation course – start your journey to becoming a web expert today!

To enable accelerated mobile pages AMP on Wordpress, simply install the official Wordpress AMP plugin, from the Wordpress plugin installation directory, or from the Wordpress website.

Wordpress AMP plugin
SAP change language accelerated mobile pages AMP version

How to add AdSense to Wordpress

There are several ways to add AdSense to Wordpress website, either by adding the code manually in the head section of the HTML output code, or by using a plugin that will do it for you.

Another solution, is to use an external advertisement service, such as Ezoic, that will manage the ads for you, and render your website to your visitors. All you have to do, is to register to Ezoic advertisement network, which includes AdSense and other ads networks, and setup your website to be served by their DNS, and it will automatically display the ads for you.

How to insert ad code in your WordPress site
SAP change language accelerated mobile pages AMP version

Wordpress AMP AdSense

The Wordpress AMP AdSense code is different than the standard AdSense for Wordpress. Make sure to include the necessary scripts for your Wordpress AMP versions corresponding to the accelerated mobile pages AMP AdSense advertisement standards.

It requires several changes in the whole website source code. An easiest way to display ads on an accelerated mobile pages AMP Wordpress site, is to use an external advertisement mediation network, such as Ezoic, that will manage the whole advertisement part for your site. All you have to do, is to enable AMP for your WordPress site, register on their ad network, and let them manage the advertisement for you.

How to insert ad code in your WordPress site

Frequently Asked Questions

How can web developers resolve the issue where the 'amp-ad extension .js script' is missing in AMP pages, ensuring ads display correctly?
To resolve this, ensure that the AMP-ad extension script (``) is included in the head of your AMP HTML document. This script is necessary for displaying ads on AMP pages and must be correctly referenced to avoid validation errors.

Yoann Bierling
About the author - Yoann Bierling
Yoann Bierling is a Web Publishing & Digital Consulting professional, making a global impact through expertise and innovation in technologies. Passionate about empowering individuals and organizations to thrive in the digital age, he is driven to deliver exceptional results and drive growth through educational content creation.

Master Website Creation: Enroll Now!

Transform your digital presence with our comprehensive Website Creation course – start your journey to becoming a web expert today!

Enroll Here

Transform your digital presence with our comprehensive Website Creation course – start your journey to becoming a web expert today!



Comments (0)

Leave a comment