How to make a custom HTML video ad

This article shows you how to create a custom HTML ad item to easily play video files on standard ad zones. For information on creating VAST ads (pre-roll, mid-roll, or post-roll ads in existing video content), read How to create a VAST ad item.

As of this writing, the IAB recommends that video ads should be at most 15 seconds long, with 6 to 8 seconds being the preferred length. The maximum recommended file size for the video creative is 1.1MB. For more information, refer to the IAB's New Ad Portfolio Guidelines (login required).

Before you follow these steps, prepare the video creative to comply with IAB's aforementioned guidelines. If you are going to assign the video ad in a zone with a fixed size, make sure that the video creative's pixel dimensions match the size of the zone.

  1. Click on Media Library on the left navigation menu, then click on Uploads. The Uploads section of the Media Library will appear.
  2. Click Add New. The New Creative page will appear.

How to upload a video ad creative

  1. Click Choose File then browse for your video creative file.
  2. Enter a name and description for the creative. (optional)
  3. Click Save Creative. You will be taken back to the Uploads section, with the video file added to the table of uploaded files.
  4. Click Copy Link on the far right of the video file's entry on the table. Paste this link into a word processor or any convenient text field, because you will use it on step 9.

How to copy the link to an ad creative

  1. Create a custom HTML ad item in the relevant campaign. For more information, read How to create a custom HTML/Third party tag ad item.
  2. Paste the following code into the Raw HTML/Script field on the ad item creation page.
<a href="[TRACKING_LINK]" title="" target="_blank">
<video width="300" height="300" muted autoplay loop>
  <source src="link to your video creative" type="video/mp4" />
  Your browser does not support the video tag.
  1. Replace link to your video creative with the link that you copied in Step 6. Be sure to retain the quotation marks in the code.

How to place the link to a video creative in a custom HTML ad item

  1. Change the values of video width and height to match the dimensions of the creative.
  2. Change the mp4 in type with the file type of your creative if it's not an MP4 file.
  3. Click Save Ad Item.
  4. Assign the campaign to the relevant zone. For more information, read How to assign a campaign to a zone or a channel.

Can't find what you're looking for?

Send us an email

Visit the blog

For more ad serving tips, industry news and AdButler insights.