Display ads
Display ads are interstitial ads consisting of a simple static image or a rich media experience that leverages MRAID. Display ads can be full-screen or MREC (medium rectangle). Unity renders MREC ads in a full-screen placement with a black background. Unlike playable ads, display ads are typically not long-form nor are they interactive.
Ad specs
The following requirements apply to display ad formats:
- Format content as a snippet of HTML or JavaScript code and not as a full HTML document or web page.
- The recommended best practice is to inline critical portions of CSS and JS to optimize the time it takes to render the ad. Load larger assets from an external resource instead of including them as inline code.
- If the content is JavaScript only, you must wrap it with
<script>
tags. - All HTML markup must reference externally-hosted assets with an absolute URL path that contains
https://
and a domain. Pointing to assets fromfile://
or a relative URL path does not work. - The advertising partner is responsible for scaling and centering content. Unity loads content to the top-left corner by default. Use CSS to avoid this if you want to center your content for various mobile screen sizes.
Also refer to the documentation on supported MRAID methods.
Note: The recommended best practice is to use the information sent in the bid request to send assets that are optimized for the device, platform, and network connection specified in the request.
Example of HTML with hyperlink
<a href="https://click-link-with-tracking.com/click?with-click-information"><img src="https://host-url.com/display/ad_image.fig" width="320" height="480"></a><img height="1" width="1" src="https://impression-tracking.com/pixel?id=1234">
<script src=”https://verification.com/omid_verification.js”></script>
Example of HTML with a JS script:
<a href="https://click-link-with-tracking.com/click?with-click-information"><img src="https://host-url.com/display/ad_image.fig" width="320" height="480"></a><img height="1" width="1" src="https://impression-tracking.com/pixel?id=1234">
<script src=”https://verification.com/omid_verification.js”></script>
Open Measurement
Unity supports Open Measurement (OM) third-party code with your ad content.
To implement OM code in your ad content, include the verification script in the HTML code.
For example:
<a href="https://click-link-with-tracking.com/click?with-click-information"><img src="https://host-url.com/display/ad_image.fig" width="320" height="480"></a><img height="1" width="1" src="https://impression-tracking.com/pixel?id=1234">
<script src=”https://verification.com/omid_verification.js”></script>