Ads not rendering

Ad delivery is a multi-step process, and an error at any stage can prevent rendering. If ads did not render, but you think that everything is setup correctly, there are several things that might be wrong. We suggest that you work through the following troubleshooting instructions in order. Verify that each step is correct before moving to the next one. If you are unable to identify the problem using these steps, please contact HTL for assistance.

1. Verify the htlbid.js script is being fetched

When the script is fetched, you should see it in the network traffic

  • open the Dev Tools
  • locate a request to htlbid.com for the file htlbid.js
  • with the correct URL for your site, ex /v3/example.com/htlbid.js
  • and a status=200 response code
image

2. Verify the correct DIV is on the page

A <div> with the correct class name must exist on the page. The class name of the DIV must exactly match the “selector” listed in the HTL BID user interface. If the wrong class name is used, no ad will be rendered.

image

3. Verify the htlbid.layout() function is called

The webpage must call the htlbid.layout() function to initiate ad rendering. You can verify that layout() was called by appending ?htlbid_debug=true to the query string and viewing the console log. Alternatively, you could set a breakpoint.

image

4. Verify the slot is eligible for the current screen size

By default, slots are configured to appear on all screen sizes. However, if you adjusted the size mapping settings in the UI, then your slot may be configured to only appear on specific screen sizes. Verify in the UI that “All Viewports” is selected.

image

5. Verify the ad request is sent to GAM

If the script is loaded, the div exists, and layout() is called, then you should see an ad request being sent to GAM. You can find the ad request in the network tab of the developer tools by filtering for ads?. If your page has multiple ads, there may be multiple requests to GAM. Inspect the Payload tab to distinguish between requests. If you don’t see any ad requests, re-verify the earlier steps and check for javascript errors in the console.

image

7. Verify the GAM ad response contains an ad

Click the “response” tab of the ad request to see the ad returned from GAM. The response from Google should have a status=200 code. Any other status code indicates an error.

A normal ad response looks like this

image

An empty response looks like this. Note that all the fields are “null”. This occurs when there are no eligible creatives to fulfill the ad request.

image

An empty ad response means one of two things. Either

  • Incorrect GAM Network ID, Ad Unit, Size or Targeting (sending the wrong data)
  • Line Item / Creative configured incorrectly in GAM

8. Verify the DIV is not hidden or removed from the page

If you are getting a successful ad response from Google that contains an ad creative, the ad will render, however, the DIV containing the ad might be hidden, or it might have been dynamically removed from the page using javascript.

In this screenshot, the ad exists and has been rendered successfully, but it is hidden with CSS.

image

9. Verify the ad creative actually works (standalone)

Certain ad creatives, especially 3rd party creatives, make heavy use of Javascript and may not render for a variety of reasons unrelated to your website or use of the HTL BID system. If all the other steps are working, it might be the creative code that is causing problems.

To ensure that the creative itself is not the problem:

  • Learn how to Preview a Creative in GAM
  • Test using a static banner image instead, without any javascript or 3rd party code

Still having problems?

Ads still not rendering? Contact HTL for help. The debugging steps above cover the most common problems that lead to blank ads, but there could also be something weird going on — for example, your domain might be blocked by Google. If you’ve tried the steps above and cannot identify the problem, please contact HTL so that we can assist you.