Fix error messages in uploaded HTML5 ads

Soon, Flash ads that were automatically converted to HTML5 format and any remaining Flash ads won't be served. This change follows the 2016 announcement that Display Network ads on AdWords will only serve in the HTML5 format.

Update your Flash ads to ensure that your ads will continue to serve.

When uploading creatives in AdWords, you may receive an error message. In most situations, the problem can be fixed by altering your file and re-saving. You can then try to upload your file again.

Check your ads using the AdWords HTML5 validator.

This article will help you to respond to specific error messages that you may receive while trying to upload creatives. For more detailed requirements, check our Image Policy page.

HTML5 ads

HTML5 ads created using the Swiffy tool aren't supported. Upload the original Flash file.

To convert your Flash ads to HTML5, only upload Flash files to AdWords. If you use the Swiffy conversion tool, the ads will not be accepted. You can also rebuild the ads using Google Web Designer or other tools. Find out more about converting your Flash ads to HTML5.

The ad contains an unsupported file type. To fix the problem, remove any unsupported file types.

To see if your .ZIP contains an unsupported file type, try the following:

  1. Open the .ZIP by double-clicking on it.
  2. In the resulting folder, make sure that each file is one of the supported file types: .CSS, .JS, .HTML, .GIF, .PNG, .JPEG and .SVG. If you find one that isn't supported, remove it.
  3. To save your updated version, select all of the files in the folder, and click on File > Compress items.
  4. If your folder doesn't zip correctly, it might be because you compressed the folder. Make sure that you select each item, not the entire folder.
The file size for your ad is too big. Upload an ad less than 150 KB in size.
Note that the 150 KB applies to all of the files in your .ZIP. You can check the size of your files by selecting the files and using File > Get Info or File > Properties, depending on your computer. The pop-up box will indicate the size in KB.
The ad you uploaded includes a file path or file name with characters other than letters, numbers, periods (.), hyphens (-) and underscore (_). 

To see if your .ZIP file contains filenames with unsupported characters, try the following:

  1. Open the .ZIP file by double-clicking on it.
  2. In the resulting folder, make sure that each file name uses only supported characters: letters, numbers, periods (.), hyphens (-) and underscores (_). Rename files with names that contain characters other than the supported ones. If you have subfolders in your .ZIP file, make sure that you open and inspect those files too.
  3. To save your updated version, select all of the files in the folder, and click File > Compress items.
  4. If your folder doesn't zip correctly, it might be because you compressed the folder. Make sure that you select each item, not the entire folder.
The ad that you uploaded contains HTML5 code that doesn't meet AdWords policies.

To fix the problem, search for the above unsupported tags in your creative code. You’ll need to check all files stored within your .ZIP file and delete them.

In many cases, the problem is with unsupported .SVG tags. In this case, search your creative code for tags that aren't included in one of the supported categories (container elements, gradient elements and graphics elements). Find out more about which supported tags are mapped to which categories.

Your HTML5 ad is missing a primary .HTML file. Make sure that there's an .HTML file with an Ad Size tag in your HTML5 ad, and try again. An Ad Size tag should look like <meta name=”ad.size” content=”width=300,height=250”>.

Primary .HTML files include an Ad Size tag such as <meta name=”ad.size” content=”width=300,height=250”>.

  1. Open your .HTML file and search for the Ad Size meta tag. If you find it, make sure it’s contained in the <head> tag and that the <head> statement is closed with a </head>.
  2. Replace quotation marks manually as copy/pasted ones can throw an error (aren't accepted by AdWords).
  3. This error can also appear when you try to upload files from DCLK Studio or the Swiffy tool. Those files aren't accepted by AdWords and can't be uploaded. DCLK should be trafficked via 3PAS per usual and Swiffy Flash files should be uploaded as Flash, not converted HTML5.
Your HTML5 ad is trying to reference an asset that we can't find in your .ZIP file.

Make sure that the filename of all files in your .ZIP file are exactly the same as the name listed in the reference file.

For example, if one of the files in your .ZIP file is called path/to/example/asset, but in your HTML file you reference path/to/example/asset2, AdWords won't be able to find the correct file.

To fix the problem, compare the filename listed above with every file in your HTML5 code. If it isn't exactly the same, correct the reference.

Your HTML5 ad is trying to reference an asset not found in your .ZIP file. Make sure that your .ZIP file only references internal assets.

You can only reference files found in your uploaded .ZIP file, and the file listed above isn't found there. To continue, remove any references in your HTML file to assets found outside of the .ZIP file.

The asset listed in the error message can't be found in your .ZIP file.  You'll also need to remove any references to that file. The only allowed external references are the following:

  • Google Fonts
  • Google-hosted jQuery
The .ZIP file can't be processed because the file itself or one of the files inside it was corrupted.

To fix corrupted files inside your .ZIP, try the following:

  1. Open the .ZIP file by double-clicking on it.
  2. In the resulting folder, open each individual file and save it again.
  3. To save your updated version, select all of the files in the folder, and click File > Compress items.
  4. If your folder doesn't zip correctly, it might be because you compressed the folder. Make sure that you select each item, not the entire folder.
Your HTML5 ad is modifying clickability, which is not supported.
The use of Tap Area in HTML5 ads created in Google Web Designer and the use of Javascript Exitapi.exit() in ads created in other tools is not supported.
If your HTML5 is built by Google Web Designer, please delete tap area component.
The changes do not impact dynamic remarketing ads built with Google Web Designer (GWD) so for these ads, there's no need for you to remove tap area and re-upload.  
If your HTML5 is from other tools, please remove the ExitApi script from the <head> section of your index.html file.
  • <script src="https://tpc.googlesyndication.com/pagead/gadgets/html5/api/exitapi.js"></script>

After removing this script tag, your entire ad will be clickable. You can leave the button but any click on the ad will take the user to the landing page. 

Remove your onclick event to call the ExitAPI.exit from your index.html file.

  • For example: <button onclick="ExitApi.exit()">

AMPHTML ads

The HTML document was rejected by the canonical AMP validator.
Alert message Your HTML file is not a valid AMPHTML ads document. Please check it with the AMP validator first.
Solution Make sure the AMPHTML ads pass the validation using this publicly available AMP validator.
Best practice Use the AMP validator before uploading your HTML documents.
Critical internal errors occurred during ad bundle validation.
Alert message Internal error occurred. If the error still persists, reach out to the support team with the testing bundle. We will look into the issue at the earliest.
Solution N/A
The custom AMP element is not supported in AdWords.

Example: An AMP custom element like <amp-audio> is not supported.

Alert message AMP custom element <$name> is not supported.
Solution Remove the unsupported AMP elements as well as their javascript imports from the HTML. 
For example:
<amp-audio width=”400” height=”300” src=”audios/myaudio.mp3”></amp-audio> from the <body> section, and also
<script async custom-element=”amp-audio” src=”https://cdn.ampproject.org/v0/amp-audio-0.1.js”></script> from the <head> section.
Best practice Only use supported AMP elements.
A custom AMP element is not supported in AdWords.

Example: Unsupported AMP custom element <amp-audio> is imported.

Alert message Unsupported AMP custom element <$name> is imported.
Solution Remove the unsupported AMP elements as well as their javascript imports from the HTML. 
For example:
<amp-audio width=”400” height=”300” src=”audios/myaudio.mp3”></amp-audio> from the <body> section, and also
<script async custom-element=”amp-audio” src=”https://cdn.ampproject.org/v0/amp-audio-0.1.js”></script> from the <head> section.
Best practice Only use supported AMP elements.
The bundle contains a media asset with a reserved asset path.

Example: Forbidden asset path: _a4a/invalid.

Alert message Forbidden asset path: $assetPath.
Solution Rename the directory.
Best practice Avoid using reserved directory names for asset paths, such as “_a4a.”
Parsing errors found in amp-custom style block.

Example: CSS parsing error: ”... .foo:nth-child(1n) { color: red } …”.

Alert message CSS parsing error: ”... .foo:nth-child(1n) { color: red } …”.
Solution Fix the errors in the attached CSS snippet. Most of the time these errors are related to CSS pseudo selectors, which are not supported in the current AdWords experience. Please remove them from the amp-custom style block.
The attribute contains an invalid value.

Example: The attribute “srcset” in tag “amp-ing” contains invalid value “a b c”.

Alert message The attribute “$attrName” in tag “$tagName” contains invalid value “$value”.
Solution This usually means that the attribute value is malformed. For example, the “on” attribute may contain a malformed event action. See the current AMPHTML specifications to see the correct value format.
The attribute contains a forbidden value.

Example: The attribute “class” in tag “div” contains value “amp-carousel-slide,” which is forbidden.

Alert message The attribute “$attrName” in tag “$tagName” contains value “$value” that is forbidden.
Solution Check to make sure that your attributes don’t contain any reserved values. Element classes shouldn’t contain reserved class names like “amp-carousel-button.” Likewise, “AMP” is not allowed as the target of an event action. 
Best practice You may want to refer to the AdWords AMPHTML ads specifications and see the list of disallowed values before creating your ads.
A configuration item is missing.

Example: Missing “finalURL” for “exit1” in tag “amp-ad-exit” configuration.

Alert message Missing “$value” for “$item” in tag “$tagName” configuration.
Solution AMP elements like <amp-ad-exit> and <amp-animation> require a JSON configuration. Please refer to the corresponding AMP element specifications for the valid configuration format.
A configuration item contains an invalid value.

Example: Invalid value for “selector” in tag “amp-ad-exist” configuration.

Alert message Invalid “$value” for “$item” in tag “$tagName” configuration.
Solution AMP elements like <amp-ad-exit> and <amp-animation> require a JSON configuration. Please refer to the corresponding AMP element specifications for the valid configuration format.
A configuration item is not supported in AdWords.

Example: “Filters” is not a supported tag in “amp-ad-exit” configuration.

Alert message $item” is not supported in tag “$tagName” configuration.
Solution The configuration item is not supported in AdWords. Remove it from the configuration.
The AMP document contains multiple occurrences of an element/value that should appear only once.

Example: Multiple occurences of “amp-ad-exit”.

Alert message Found multiple occurrences of “$item”.
Solution Remove those extra elements from the document and keep only the one instance.
A custom exit in AMPHTML ad bundle is not supported.

Example: Your AMPHTML ad has modified clickability, “tap:exit-api.exit(target=’product1’)”, which is not supported.

Alert message Your AMPHTML ad has modified clickability, “$exit”, which is not supported.
Solution Remove the <amp-ad-exit> configuration and javascript import from the HTML. Remove the event actions that invoke exit-api.exit (for example, <button on=”tap:exit-api.exit(target=’product1’)”>)
Ads contain multiple HTML files.
Alert message The ad contains multiple entry points. Make sure there is only one .HTML file with an ad size tag in your HTML5 ad and try again.
Solution Make sure there is only one HTML file to show ad content in the .zip file, and remove the extra HTML files.
A CSS rule contains a forbidden property value.

Example: The CSS property value “width:100%” is not allowed for selector “.amp-carousel-button.”

Alert message The CSS property value “$cssPropertyName:$cssPropertyValue” is not allowed for selector “$cssSelector.”
Solution Remove the CSS property value indicated in the message from the amp-custom style block.

Google Web Designer HTML5

Note: To build AMPHTML banner ads in Google Web Designer, the initial step is presented in the New File dialog, where you can click AMPHTML banner to begin creating the ad. For AMPHTML ads, Google Web Designer has restrictions on certain functionality. For more information, read this article about AMPHTML ads.
You must upload a published file. You must publish your file in Google Web Designer before you can upload it to AdWords.
To upload your ad, you must upload a published file, not the author file. Before you can upload your ad, you must open the author file in Google Web Designer and choose the options: Publish > Publish Locally. Find out more.
This ad was created with the environment "Generic" instead of "AdWords". To continue, convert the file to an "Adwords" environment in Google Web Designer.
When creating the ad, you selected the wrong environment. Your ad was created with the “Generic” environment instead of “AdWords”. To continue, you must convert the file to an “AdWords” environment. Find out more about environment conversion.
The ad you uploaded contains HTML5 code that violates AdWords policies. Remove any references to the tags listed above before you upload your ads.

Your ad violates one of the AdWords policies. See problems listed in the original error message.  

Before you can upload your ad, you'll need to remove any unsupported features. You can do this by opening the index.html file in your .ZIP file. You can find unsupported features in the "gwd-admetadata" section.

  • Expandable ad: Search "creativeProperties". The minWidth should equal maxWidth and minHeight should equal maxHeight.
  • Counters or timers: Search “counters” or “timers”. These arrays should be empty.
  • Multiple exits
  • Videos
  • Maps
  • You can find a complete list of Supported features here.
Your HTML5 ad is trying to reference an asset not found in your .ZIP file. Make sure that your .ZIP file only references internal assets.

In Google Web Designer, you must include images for all visual states of the image button.

For example, in the below code snippet from an example index.html file, the images for the up-image, over-image and the down-image are missing (see bolded text).

<gwd-imagebutton id="gwd-imagebutton_1" up-image="" over-image="" down-image="" scaling="cover" class="gwd-imagebutton-tcf2"></gwd-imagebutton>

Find out more about the image button component.

To fix the problem, replace the placeholder.png with the image(s) you want to use and make sure that the image is included in the .ZIP file.

Note: The error message should explain what's missing. In some cases, you’ll see "" as missing. In this case, it's likely that the image location wasn't specified. Open your .ZIP file and locate your index.html file. Inside, you can search for ' ="" to find the error.

 

If you want to learn more about the issue described in this article, please check this SMEs recommended training
 

 

Was this article helpful?
How can we improve it?