Does google analytics use cookies?

Google Analytics uses “cookies to identify unique users across browsing sessions”. These cookies help remember a visitor’s previous interactions on a website and identify unique users.

When someone visits a website, Google Analytics drops a cookie that stores a ClientID (cid), which is used to identify users.  GA also uses UserID (uid) to help websites to associate a single user with sessions across multiple devices. Cookies used by Google Analytics include:

  • _gid, distinguishes users for 24 hours
  • _ga, distinguishes users on a domain and lasts 2 years
  • _gat, limits the number of user requests and lasts 1 minute
  • _utmv, user-defined variable cookies that can last 2 years

GA sets first-party cookies i.e. set by the domain a user is visiting. But it can also set third-party cookies by DoubleClick if websites use the advertiser features for retargeting.