Creating the RSS feed for Turbo pages. Description and technical requirements

Description and requirements for the RSS feed for using Turbo pages in the Yandex search results.

Note. After you notify Yandex about the page, you can turn on showing Turbo pages in Yandex.Webmaster. To change the appearance and content of the pages, use the RSS feed.

Turbo pages are generated based on the site's pages. The data for Turbo pages is exported in XML-based RSS 2.0 format.

  1. Description of RSS 2.0 elements
  2. Updating the Turbo page
  3. Export file example

Description of RSS 2.0 elements

The root element of an RSS file is rss, with the version attribute set to 2.0.

<rss
    xmlns:yandex="http://news.yandex.ru"
    xmlns:media="http://search.yahoo.com/mrss/"
    xmlns:turbo="http://turbo.yandex.ru"
    version="2.0">
    ...
</rss>

To generate a Turbo page, send the following information:

...
    <channel><!--Source site (RSS feed) information-->
        ...
        <item turbo="true"><!--Page information-->
            ...
            <turbo:content>...</turbo:content><!--Page content-->
            ...
        </item>
    </channel>
</rss>
  1. Sending information about the source site
  2. Sending the information about the page
  3. Sending the page content
  4. Characters and encodings

Sending information about the source site

The data is passed in the channel element.

Element Description
title

The name of the RSS feed.

If you export the content of the whole site, enter the site name. If you export a site section, enter just the section title.

<title>The RSS feed title</title>
link

Domain of the site from which the data is passed.

<link>http://www.example.com</link>
description

Channel description in one sentence. Don't use HTML markup.

<description>Short description of the feed</description>
language
The article language in ISO 639-1 format.
<language>ru</language>
yandex:analytics

Traffic counter for Turbo pages.

You can specify several Yandex.Metrica counters and one counter per every other system.

To count the Turbo pages traffic with multiple web analytics systems, add multiple yandex:analytics elements to the channel element:
Yandex.Metrica

Add the type attribute set to Yandex and specify the counter number in the id attribute.

<yandex:analytics id="counter number" type="Yandex"></yandex:analytics>
LiveInternet
Set the type attribute to LiveInternet.
<yandex:analytics type="LiveInternet"></yandex:analytics>

If a counter is used for several hosts, add the params attribute with the counter name.

<yandex:analytics type="LiveInternet" params="Counter name"></yandex:analytics>
Google Analytics

Set the type attribute to Google and the id attribute to the counter ID.

<yandex:analytics id = "counter ID" type = "Google"> </yandex:analytics>
Rating Mail.RU

Set the type attribute to MailRu and the id attribute to the counter ID.

<yandex:analytics id="counter ID" type="MailRu"></yandex:analytics>
Rambler Top 100

Set the type attribute to Rambler and the id attribute to the counter ID.

<yandex:analytics id="Rambler ID" type="Rambler"></yandex:analytics>
Mediascope (TNS)
Set the type attribute to Mediascopeand the id attribute to the counter number.
<yandex:analytics id="Mediascope tmsec ID" type="Mediascope"></yandex:analytics>
yandex:adNetwork

Use it to display Yandex advertising network ad blocks and third-party adverts placed on Turbo pages with ADFOX. Also, use it to track the advertising revenue from Turbo pages. The element is added once.

To set the ad block location on the page, specify alphabetic IDs in the turbo-ad-id attribute. For example, first_ad_place, second_ad_place. To specify the actual location of the ad on the page, add the same attribute to the figure element nested in the turbo:content element.

If the turbo-ad-id attribute is not specified, the ad will be placed at the end of the Turbo page.

Yandex Advertising Network

In the partner interface, create an ad block for Turbo pages. In the RSS file, add the type attribute set to Yandex and the id attribute with an alphanumeric ID of the ad block.

<yandex:adNetwork type="Yandex" id="block ID" turbo-ad-id="first_ad_place"></yandex:adNetwork>
ADFOX
In ADFOX, create a platform for Turbo pages. In the RSS file, add the type attribute set to AdFox value. In the yandex:adNetwork element, add the block code wrapped in the <![CDATA[]]> tag.
<yandex:adNetwork type="AdFox" turbo-ad-id="second_ad_place">
    <![CDATA[
        <div id="container ID"></div>
        <script>
            window.Ya.adfoxCode.create({
                ownerId: 123456,
                containerId: 'container ID',
                params: {
                    pp: 'g',
                    ps: 'cmic',
                    p2: 'fqem'
                }
            });
        </script>
    ]]>
</yandex:adNetwork>
item*

Page and content information.

To use the Turbo pages format, add theturbo attribute set to true. To disable the display of a Turbo page, set the value to false. For details, see the Controlling display of Turbo pages section.

...
    <item turbo="true">
        ... 
    </item>

One item element describes one page.

* Required element.

Sending the information about the page

The data is sent in the item element.

Element Description
link*

Source page URL.

<link>http://www.example.com/page1.html</link>
Requirements:
  • The link must contain the HTTP or HTTPS prefix.
  • The link domain must be the same as the source site domain.
  • Maximum URL length is 243 ASCII characters.
  • A URL must contain one article.

When the link is clicked, the header and the beginning of the text should fit the first screen at the 1024 × 768 resolution.

pubDate*

The time when the content was published on the source site.

Sent in RFC-822 format.

<pubDate>Tue, 21 Apr 2015 14:15:00 +0300</pubDate>
author The author of the article published on the page.
<author>Ivan Ivanov</author>
turbo:content*

Page content.

yandex:related

A section with links to other site pages. Contains the link element. The number of nested elements is unlimited.

To add an image to the article, use the img attribute with the image URL.

The text wrapped into the link element shouldn't contain the HTML elements.
<yandex:related>
<link url="http://www.example.com/page.html" img="http://www.example.com/image.png">Link text</link>
</yandex:related>

* Required element.

Sending the page content

Turbo page content is sent in the turbo:content element. The contents should be wrapped in the <![CDATA[]]> tag.

The page header (the top of the page)

Use the header element that can contain:

Element Description
figure Contains the img element with the cover image URL. The image can be in any format.
<header>
    <figure>
        <img src="http://example.com/img.jpg" />
    </figure>
    ...
h1* Level one heading.
<h1>Heading text</h1>
h2 Level two heading.

* Required element.

Text formatting
Element Description
h1
Level one heading.
<h1>Page title</h1>

Supports six levels of headings.

p
Paragraph.
<p>Text paragraph</p>
br
Line break without indent.
<br>Text</br>
ul
Unordered list.
<ul>
    <li>first item</li>
</ul>
ol
Ordered list.
<ol>
    <li>first item</li>
</ol>
b
Bold text.
<b>Text</b>
strong Text selection. Usually browsers display it in bold.
<strong>Text</strong>
i Italicized text.
<i>Text</i>
em Text selection. Usually browsers display it in italics.
<em>Text</em>
sup Superscript text.
2<sup>3</sup>
sub Subscript text.
H<sub>2</sub>O
ins

Text added in the new version of the article. Most browsers display it underlined.

Main text,  <ins>new text</ins>
del

Text deleted in the new version of the article. Most browsers display it with strikethrough.

Main text, <del>deleted text</del>
small
Font size reduced by one point.
<small>Text</small>
big Font size increased by one point.
<big>Text</big>
pre
Previously formatted text.
<pre>Text</pre>
abbr Abbreviations in the text.
<abbr title="Details">HTML</abbr>
u
Underlined text.
<u>Text</u>
Link in the text
Use the a element with the href attribute that contains the URL.
<a href="https://www.example.com/page2.html">Link text</a>
Picture in the text

Use the figure element that can contain:

Element Description
img The src attribute contains the image URL. The image can be in the JPEG or PNG format.
...
    <figure>
        <img src="http://example.com/img.jpg" />
    </figure>
...
figcaption Visible picture caption.
 ...
    <figure>
        <img src="http://example.com/img.jpg" />
        <figcaption>Caption</figcaption>
    </figure>
...
Video in the text

Supports the MP4 format. Use the figure element that can contain:

Element Description
video Contains the source element with the attributes:
  • src — Link to the video. The video should be available over HTTPS.
  • type — Media type and format.
...
<figure>
    <video>
        <source src="https://example.com/video.mp4" type="video/mp4" />
    </video>
    ...
img Video (or image) preview in any format.
...
<figure>
    <video>
        <source src="https://example.com/video.mp4" type="video/mp4" />
    </video>
    <img src="http://example.com/img.jpg" />
    ...
figcaption Video caption.
...
<figure>
    <video>
        <source src="https://example.com/video.mp4" type="video/mp4" />
    </video>
    <img src="http://example.com/img.jpg" />
    <figcaption>Video caption</figcaption>
</figure>
Specifying the ad block place
To specify the place for the ad block on the page, use the figure element. It should contain the data-turbo-ad-id parameter set to the same value as the yandex:adNetwork element.
<figure data-turbo-ad-id="first_ad_place"></figure>

Characters and encodings

In the export file, specify the encoding sent by your server. The most commonly used encodings are: UTF-8, Windows-1251, KOI8-R.

In all nested elements of channel and item, encode the following characters:

Character Name Replacement code
& Ampersand &
> Right angle bracket >
< Left angle bracket <
" Inverted commas "
' Apostrophe '

For example, the link http://example.com/?id=1&page=10 should look like http://example.com/?id=1&page=10.

Updating the Turbo page

To update the information about the Turbo page and its content:
  1. Edit the RSS file on your site server. The Yandex robot downloads the file every hour.
    Note. The file must be accessible via the HTTP or HTTPS protocol. If a robot couldn't download it for 10 seconds, the file is considered unaccessible. In this case, a loading error is displayed in the Turbo pages section of Yandex.Webmaster.
  2. Yandex has several indexing robots. The RSS feed is downloaded by the main robot. To index the file, add the Allow directive to the robots.txt file:

    User-agent: YandexBot
    Allow: /file.rss
    ...
    #the last line must be empty

    You can check the correctness of the robots.txt file in the Yandex.Webmaster.

    If you use the Crawl-delay directive in the robots.txt file, specify it for the robot separately (with a value from 0.1 to 2).

    User-agent: YandexBot
    Allow: /file.rss
    Crawl-delay: 0.1
    ...
    #the last line must be empty

If you don't want the robot to check the RSS feed, in the Turbo pages section of Yandex.Webmaster, set the option next to the source to the Off position.

Export file example

    <?xml version="1.0" encoding="windows-1251"?>
    <rss
        xmlns:yandex="http://news.yandex.ru"
        xmlns:media="http://search.yahoo.com/mrss/"
        xmlns:turbo="http://turbo.yandex.ru"
        version="2.0"
    >
        <channel>
            <title>Rss feed title</title>
            <link>http://www.example.com/</link>
            <description>Short description of RSS feed</description>
            <yandex:analytics type="Yandex" id="123456"></yandex:analytics>
            <yandex:adNetwork type="AdFox" turbo-ad-id="first_ad_place">
                <![CDATA[
                    <div id="container ID"></div>
                    <script>
                        window.Ya.adfoxCode.create({
                            ownerId: 123456,
                            containerId: 'container ID',
                            params: {
                                pp: 'g',
                                ps: 'cmic',
                                p2: 'fqem'
                            }
                        });
                    </script>
                 ]]>
             </yandex:adNetwork>
             <item turbo="true">
                 <link>http://www.example.com/page1.html</link>
                 <author>Ivan Ivanov</author>
                 <category>Technologies</category>
                 <pubDate>Sun, 29 Sep 2002 19:59:01 +0300</pubDate>
                 <turbo:content>
                     <![CDATA[
                         <header>
                             <figure>
                                 <img src="http://example.com/img.jpg" />
                             </figure>
                             <h1>Page header</h1>
                         </header>
                         <h2>Page header</h2>
                         <p>Text with <b>formatting</b> and a list:</p>
                         <ul>
                             <li>item 1;</li>
                             <li>item 2.</li>
                         </ul>
                         <figure data-turbo-ad-id="first_ad_place"></figure>
                         <figure>
                             <video>
                                 <source src="https://example.com/video.mp4" type="video/mp4" />
                             </video>
                             <img src="http://example.com/img-for-video.jpg" />
                             <figcaption>Video caption</figcaption>
                         </figure>
                      ]]>
                  </turbo:content>
                  <yandex:related>
                      <link url="http://www.example.com/other-page.html" img="http://www.example.com/image.jpg">Link text</link>
                  </yandex:related>
              </item>
          </channel>
      </rss>