Metrica

Counter code

You can use the options in this section to get the counter code and customize it before installing it on website pages.

Note the following counter settings:

  • WebVisor records and analyzes user actions on your website. More information about setting up WebVisor.
  • The scroll map is a tool for analyzing how site users pay attention to particular areas of the page.
  • Form analysis is a tool for analyzing fill-in forms (order forms, contact forms, and so on).
  • Hash tracking in the browser address bar — this option is applied for AJAX sites and allows correct calculation of the number of pageviews on pages that are updated without being refreshed.
  • Asynchronous code — does not block pages and does not affect page loading speed.
  • For XML sites — the noscript element must not be used in XML documents.
  • Stop automatic page indexing — webpages containing a Yandex.Metrica counter will not automatically be indexed.
  • Informer — allows you to select the counter display mode: invisible or with a button where your site's traffic statistics are displayed. To select the type of informer and set up how it looks, click Settings.

    The informer displays data collected by the counter during the current day (this period isn't configured by the user).

  • Dispatch ecommerce data to Metrica — this option lets you enable Ecommerce via the web interface. If the option is on, by default the JavaScript array is assigned the name dataLayer. You can change it in the Name of data container field.
Note. 
  • If you change any counter settings, don’t forget to replace the old code on all the pages.

  • The counter transmits data to the Yandex.Metrica server over the HTTPS protocol.

  • If you only install the informer code (<!-- Yandex.Metrica informer -->) on a site without the counter code, statistics aren't collected for the site.

Questions and answers about the informer

The informer does not display data

Make sure the informer is enabled. In the Settings section (on the Counter code tab), the Informer option must be selected. If this option is disabled, save changes after enabling it and update the counter code on the website pages.

The label “Yandex.Metrica” is shown instead of the informer

Check whether the website where you are expecting to see the informer has been added as an additional domain in the counter settings. Without this setting, data is not displayed.