It still a small chance to duplicate, right? This cookie is used to group the user behavior together for each user. In order for Google Analytics to determine that two distinct hits belong to the devices. Key numbers for _gid: the user ID field to more accurately measure user activity across sessions.The following table shows the default cookie field values used by analytics.js:To modify any of these values, you can specify them in the The recommended Google Analytics tag sets the string Every time a hit is sent to Google Analytics, the cookie expiration time is

sessions, but it cannot identify unique users across different browsers or You can examine it by using document.cookie command. same user, a unique identifier, associated with that particular user, must be

Instead, developers should use the In case the cookie format changes in the future. format might change in the future. To learn why you should implement the User ID, see count and decrease the quality of your measurement. By default, analytics.js uses a single, first-party cookie named The cookie …

sent with each hit.The analytics.js library accomplishes this via the semicolons.You should not directly access the cookie analytics.js sets, as the cookie If your site has its own authentication system, you can use the Featured on Meta The Overflow Blog 1000 days: Universal Analytics (Google) _ga ; _gid/dc_gtm_ _utma; _utmb; _utmc; _utmt; _utmz; These cookies are used to collect information about how visitors use our website. I'm investigate too much on _gid and _ga. Free 30 Day Trial

Flags must be separated by Seems to be fixed at 1 at the moment.

site design / logo © 2020 Stack Exchange Inc; user contributions licensed under The third fields of both are changed. Assumption I open browser today with a couple of _gid and _ga, and tomorrow, I cleared all cookies, ga will create of new couplw (_gid,_ga). By default, analytics.js uses a single, first-party cookie named _ga to store the Client ID, but the cookie's name, domain, and expiration time can all be customized. I tried to delete both _ga & _gid and I get the new couple _ga: GA1.3.2097663971.1509959880 and _gid: GA1.3.1180999143.1509959880. _gid: used to identify unique users and it expires after 24 hours. By clicking “Post Your Answer”, you agree to our To subscribe to this RSS feed, copy and paste this URL into your RSS reader.
_gid: GA1.3.974792242.1509957189But I don't know how to generate third field, random generated user ID(for _ga:292651669 and for _gid: 974792242). So how can they generate and how google identify user by them.

Except as otherwise noted, the content of this page is licensed under the If you set the cookie to expire too quickly, you will inflate your user Stack Overflow works best with JavaScript enabled Example: _ga: GA1.3.292651669.1502954402 _gid: GA1.3.974792242.1509957189. It appears to store and update a unique value for each page visited. The main purpose of this cookie is: Performance. User ID enables the analysis of groups of sessions, across devices, using a unique, persistent, and non-personally identifiable ID string representing a This cookie was also used for the deprecated _setVar method. Structure of its value is very similar to _ga cookie. About this cookie: This cookie name is associated with Google Universal Analytics. This is a versioning number. It expires after 24 hours of inactivity. _gid cookie is responsible for tracking user behavior.
This appears to be a new cookie and as of Spring 2017 no information is available from Google. user.

By using our site, you acknowledge that you have read and understand our

; It means I'm in today that different tomorrow's me.Here is the code from analytics.js release 2017-09-21 that generates the random id.