Declan Murray
Ad Tech
Feature
Self-Service
Tutorials
EXADS has added the ability for Publishers to use Asynchronous Tags for desktop and mobile banners ad zones. When creating either of these zone types, Publishers can use these tags to ensure that zones are loaded onto the page asynchronously.
As a Publisher, you can of course continue to use the two older scripts we provide: Standard and iFrame. Currently, some Publishers use the iFrame to ensure their page never gets blocked from loading. They can continue to use it, but this new script has the same advantages, only with increased performance and ease of use. Google rankings of sites are partially based on performance, so the performance increase can result in improved Google rankings also.
To use an asynchronous tag, from the main screen of the Admin Panel, click on New Zone and select either Banner or Mobile Banner. Once you have filled in the details for the new zone, you will be taken to the Your Zone HTML Tag screen. From the Select tag type drop-down, select Asynchronous Script.
This will create an asynchronous script like this:
<script async type="application/javascript" src="https://a.examplesite.com/ad-provider.js"></script> <ins class="adsbynetwork" data-zoneid="1234567"></ins>
<script>
(AdProvider = window.AdProvider || []).push({"serve": {}});
</script>
You can use this script to show either a single zone that is loaded asynchronously or to put multiple existing banner zones onto a single page.
To use the script for a single zone, simply copy the code onto your site as you do with any normal script.
To use this script for multiple zones, copy the code onto your site, and repeat the middle section, the <ins> element, for each zone you wish to put on the page. Replace the data-zoneid with the id for these existing zones (e.g. 111, 222, 333):
<script async type="application/javascript" src="https://a.examplesite.com/ad-provider.js"></script>
<ins class="adsbynetwork" data-zoneid="111"></ins>
<ins class="adsbynetwork" data-zoneid="222"></ins>
<ins class="adsbynetwork" data-zoneid="333"></ins>
<ins class="adsbynetwork" data-zoneid="444"></ins>
<script>
(AdProvider = window.AdProvider || []).push({"serve": {}});
</script>
Document.write can impede performance, as it blocks the rendering of the entire document until it is complete. It is not normally used for regular banners, as we can use other ways of rendering content there.
HTML Banners, however, may have HTML and Javascript of their own, which may use document.write, and other code specific to them. To avoid any problems with this specific code, we constrain HTML banners within an iFrame.
If a document.write is used inside this iFrame it is not detrimental to performance, as it is not preventing anything from loading on the main page. The new asynchronous script doesn't need to use document.write for anything except HTML Banners, and will never suffer from performance issues related to document.write when serving them.
We have tested three tags on a blank website with different EXADS ad formats. The objective was to measure the amount of time it took for the page to become fully interactive (Time To Interactive) using Google PageSpeed Insights. The results are shown in the following table:
Tag |
Desktop |
Mobile |
sync |
587 ms |
1663 ms |
iFrame |
238 ms |
810 ms |
async |
232 ms |
790 ms |
As you can see, there is a significant improvement in ad loading speed using async tags compared to the previous sync tag. Specifically, there is a 2.5-fold increase on Desktop and a 2-fold increase on Mobile. The async tag is also slightly faster than the load times of iFrames. This is because async tags don’t block the page while they load. Using the new async script, website content can load while the ads are requested, which has a positive impact on the overall page load times.
Please view the video to find out about asynchronous tags:
Declan Murray
Technical Writer, EXADS
Subscribe to receive via email more information about EXADS and the ad serving market.
Thank you for subscribing.
We will send you a message when new articles are posted.
Barry O'Sullivan
We’re making 2023 the year of EXADS with some powerful new features on our Q1 Roadmap. We're talking Ad Format Configurations, Smart Bidding and Bid Shading, User Profiling and more!
Ad Serving
Ad Tech
Feature
Update
Ana Kealy
Come meet EXADS at the TES Affiliate Conferences, at Cascais Portugal, on 22-25 February 2023.
Ad Tech
Events
Update
Ana Kealy
We look at key ad tech trends for 2023 and examine the opportunities and challenges ahead. What is the future of ad tech in 2023 and beyond?
Ad Serving
Ad Tech
Tips