Features Pricing GDPR cookie banner Google Consent Mode v2 WordPress plugin Cookiebot alternative For Agencies GDPR ePrivacy About Contact
RO | EN
Start Free →
Statistics

_ym_uid – Yandex Metrica statistics cookie

_ym_uid is a statistics cookie set by the Yandex Metrica web analytics service. It assigns visitors a unique identifier used to distinguish users and measure their behavior on a site over time.

Name
_ym_uid
Provider
Yandex Metrica
Category
Statistics
Type
HTTP cookie
Lifetime
1 year
Consent
Yes, before it is set (GDPR / ePrivacy)

What is the _ym_uid cookie?

_ym_uid is a first-party HTTP cookie set by the Yandex Metrica tracking script, the free web analytics service offered by the Russian company Yandex. It appears on any website that has the Yandex Metrica tracking tag installed.

The cookie is created automatically on a user's first visit to the site, as soon as the Yandex Metrica script loads and runs in the browser.

What data it stores

_ym_uid stores a unique identifier generated for the visitor, typically a long numeric string, and does not contain directly identifying information such as a name or email address.

The value is sent to Yandex Metrica's servers, where it is used to associate the visitor's sessions and actions with this identifier for statistical reporting purposes on behalf of the site owner.

What it is used for

The cookie's main purpose is recognizing unique visitors across visits, allowing Yandex Metrica to calculate metrics such as new versus returning visitors, session duration, pages viewed, and navigation paths.

For the website owner, this data feeds traffic reports, click heatmaps, and behavior analytics available through the Yandex Metrica dashboard.

Does it require consent?

Under CookieFix's classification, _ym_uid falls under the statistics (analytics) category. Under the ePrivacy Directive (as transposed in Romania by Law 506/2004) and GDPR, this type of cookie is not strictly necessary for the site to function, so it requires the visitor's prior, informed, explicit consent before being set.

Website owners should disclose the cookie in their cookie policy, list it under the statistics category of the consent banner, and make sure the Yandex Metrica script does not run before the visitor has given consent.

How to block or delete _ym_uid

A visitor can manually delete or block _ym_uid through their browser's privacy/cookie settings, or use tracking-script blocking extensions.

  • Manual deletion: from the browser's per-site cookie settings.
  • Automatic blocking: a consent management platform (CMP) such as CookieFix can prevent the Yandex Metrica script from loading until the visitor accepts the "statistics" category in the banner, avoiding the cookie being set without consent.

Frequently asked questions

Yes, because it is used for statistical analysis and is not strictly necessary for the site to function, it requires the visitor's prior consent.

Its typical duration is about one year from being set, after which it expires automatically unless renewed by a later visit.

It is set by Yandex Metrica, the web analytics service run by Yandex, when a site integrates their tracking script.

The most effective way is using a consent management platform that blocks the Yandex Metrica script until the statistics category is accepted; visitors can also block it manually via browser settings.

Updated 7 September 2026 · Information comes from the provider’s public documentation and CookieFix scans; it is not legal advice.