Configuring Direct blocks

Creating new Yandex.Direct blocks is currently not supported. Use strategies to create RTB blocks and manage displays of contextual and banner ads.

To edit added blocks, go to the list of blocks (Products → Direct blocks), find the block you need, and click Edit.

All visual configuration changes take effect automatically (without resetting the website code) within 30 minutes after changes are saved. If a loading method (synchronous/asynchronous) or alternative ad code changes, the website code must be reset manually.

Configuring ad block design

On the Direct design tab, you can change the visual design of a block by specifying your own font and frame settings, as well as color settings with the help of a palette (click a color sample next to its 6 digit code). The display of advertisers' website icons and sitelinks can be enabled or disabled on the Formats tab. In addition, you can enable and disable the display of illustrated ads on theme-based platforms. All configuration changes will be immediately visible in the test block.

Please keep in mind that the design of your ad block significantly influences its CTR and, consequently, your site revenue.

Alternative ad display

Yandex Advertising Network partners can automatically display alternative ads (social ads, their own ads, or contextual or banner ads from other systems) if Yandex.Direct ads were not selected for their site pages. This capability can be especially useful for fixed-format ad blocks.

Enter the code on the Alternative code tab (JavaScript only, no HTML). The portion of the code required for displaying alternative ads will be compiled and added to the ad code automatically. Please note, the website code has to be reset manually after saving the block.

Asynchronous ad loading

Asynchronous ad code helps reduce the loading times of pages containing ad blocks.

If a standard (synchronous) code is used, the page content and its ad block are loaded sequentially. Asynchronous code lets you load them at the same time. This reduces the total time needed to load the page.

To install asynchronous code as Direct code insert for the website (click Get code), please select Asynchronous code. Copy JavaScript code and insert it in the page's HTML (the changes won't come into force automatically).

Insert the following code in the place where the ad block should be displayed:

<div id="yandex_direct_D-A-12345-1"></div>

For the id variable, replace yandex_direct_D-A-12345-1 with a custom ad block ID — the same as in the ad code received in the interface. The ad code copied from the ad code designer should be inserted after this element. For example, it should be inserted at the end of the page's HTML code before the </body> tag or in a separate JavaScript file.

Delayed display of ad blocks

Browsers load a page sequentially. You can place the HTML code of an ad block in any part of a page and it will still be displayed in the place that you consider to be most convenient for visitors of your site. Use this setting if you would like the ad block to be loaded after the main content of the page is loaded. For example, you can choose to display ads in the upper part of the page and place the ad code at the end of the page's HTML code.

Insert the following code in the place where the ad block should be displayed:

<div id="yandex_direct_D-A-12345-1"></div>

For the id variable, replace yandex_direct_D-A-12345-1 with a custom ad block ID — the same as in the ad code received in the interface. The ad code copied from the ad code designer should be inserted after this element, for example, at the end of the page's HTML before the </body> tag.

General settings for theme-based platforms

Please note, all settings defined for a theme-based platform function in Direct blocks.