Tip. Working with the JavaScript API requires knowledge of HTML and JavaScript. If you don't know these languages, contact your website developer or webmaster.

Transmitting custom parameters of site users.

ym(XXXXXX, 'userParams', parameters);


Default value



parameters *


User parameters.

ym(XXXXXX, 'userParams', {
    status: "Gold",
    child: 1,
    child_age: 13,
    UserID: 12345

* Required parameter.

To transmit your own user ID, use the UserID parameter. You can choose any names for other user parameters.

Up to 1000 parameters can be transmitted in a single session. When the hierarchical data structure is transmitted, the Yandex.Metrica reports will display up to 10 nesting levels.

Information passed in the userParams method becomes available in reports within a few hours.

The maximum number of characters shown in Yandex.Metrica reports:
  • In fields — 255.
  • In values — 50.