Please make sure to visit Your AdSense Page where you can find personalized information about your account to help you succeed with AdSense.

Ad units

How to generate synchronous ad code for your ad units

The ad code you generate in your AdSense account is fully asynchronous. It offers improved web latency and a better user experience for your site’s visitors. If you need to generate synchronous ad code, for example, because you're using Google Ad Manager or another ad server that doesn't support asynchronous ad code, you'll need to modify your ad unit code.

Note: You can only generate synchronous ad code for fixed-sized ad units.

To modify your existing ad unit code, make the following code updates:

Asynchronous ad unit code:

<script async src="
<!-- leaderboard -->
<ins class="adsbygoogle"
(adsbygoogle = window.adsbygoogle || []).push({});

Synchronous ad unit code:

<script type="text/javascript">
    google_ad_client = "ca-pub-xxxxxxxxxxxxxxxx";
    google_ad_slot = "1234567890";
    google_ad_width = 728;
    google_ad_height = 90;
<!-- leaderboard -->
<script type="text/javascript"
Note: We do not recommend you mix asynchronous and synchronous ad code in the same web page.

Was this helpful?

How can we improve it?
Your AdSense page

Introducing AdSense Page: a new resource in which you can find personalized information and new opportunities in your account to help to succeed with AdSense.

Clear search
Close search
Google apps
Main menu