What is the _hjHasCachedUserAttributes cookie?
_hjHasCachedUserAttributes is an HTTP cookie set by the Hotjar script, a behavioral analytics service (heatmaps, session recordings, surveys) commonly used alongside traditional web analytics tools. It's placed by the visitor's browser through Hotjar's JavaScript code, embedded directly on the site or via a tag manager.
The cookie appears as soon as the Hotjar script runs on the page, regardless of whether the site actively uses Hotjar's User Attributes feature.
What data it stores
The cookie stores an internal flag indicating whether user attributes (such as an account ID or other information the site sends to Hotjar through its API) have already been submitted and cached for the current session, avoiding repeated transmissions of the same data.
The exact value format isn't publicly documented by Hotjar; it's known to serve internal cache management rather than storing personal data directly in the cookie. Associated data is sent to Hotjar's servers (Hotjar Ltd., part of the Contentsquare group).
What it is used for
The cookie's purpose is purely technical: it prevents the browser from repeatedly resending the same user attributes to Hotjar within the same session, reducing unnecessary network traffic and keeping the analytics script running efficiently.
For the site owner, this cookie indirectly supports the collection of behavioral data (heatmaps, session recordings, feedback) used to understand how visitors interact with the page.
Does it require consent?
This cookie falls under the statistics (analytics) category, since it's generated by a behavioral analytics tool, even though its own role is strictly technical within that process. Under the GDPR (Regulation 2016/679) and the ePrivacy Directive 2002/58/EC, analytics cookies aren't strictly necessary for the site to function, so prior visitor consent is required.
Site owners should declare this cookie in their cookie policy, classify it correctly under the statistics category, and make sure the Hotjar script doesn't load before consent is obtained, in line with applicable data protection authority requirements.
How to block or delete _hjHasCachedUserAttributes
A visitor can delete or block this cookie through browser settings (Chrome, Firefox, Edge, Safari), in the per-site cookie management section, or by using tracking-blocking options built into the browser or dedicated extensions. Since it's a session cookie, it disappears automatically when the browser is closed.
- Manual deletion via browser settings
- Private/incognito browsing mode
- Anti-tracking browser extensions
For site owners, the most reliable approach is using a CMP like CookieFix, which automatically script-blocks the Hotjar code (including this cookie) until the visitor gives consent for the statistics category.
Frequently asked questions
It's a session cookie set by Hotjar that flags whether user attributes have already been cached for the current session, avoiding repeated data transmissions.
It doesn't directly store personal data in its value; it's an internal technical flag Hotjar uses to optimize the analytics session.
Yes, since it's part of Hotjar's analytics cookie suite, it requires the visitor's prior consent under GDPR and applicable ePrivacy rules.
It's a session cookie and is automatically deleted when the browser is closed.