Mastering Hotjar Auto‑Tag Events: A Beginner’s Guide
Introduction
Ever wondered why some Hotjar recordings show clicks on buttons that you never manually tagged? The secret lies in Hotjar Auto‑Tag Events. This feature automatically adds event tags to user interactions, giving you richer insights without the extra coding work.
What Are Auto‑Tag Events?
Auto‑Tag Events are predefined UI interactions that Hotjar detects and labels for you. When a visitor clicks, scrolls, or navigates, Hotjar attaches a tag like click:button or scroll:percentage to the recording. These tags appear in the heatmap and session replay, making it easy to spot where users engage the most.
Key Benefits
- Time‑saving: No need to add custom JavaScript for every button or link.
- Consistency: Tags follow a standard naming convention, simplifying analysis.
- Actionable data: Quickly identify friction points and conversion blockers.
How Auto‑Tag Events Work
Hotjar scans the DOM after the script loads and automatically assigns tags based on element types and attributes. The process runs in three steps:
- Detection: Hotjar looks for clickable elements (e.g.,
<button>,<a>,<input type="submit">). - Classification: It categorises the interaction (click, focus, change, scroll).
- Tagging: A readable label is added to the event log, visible in the Hotjar dashboard.
Setting Up Auto‑Tag Events
Most users get auto‑tagging out of the box, but you can fine‑tune the behavior to match your site’s structure.
1. Install the Hotjar Tracking Code
<script> (function(h,o,t,j,a,r){ h.hj=h.hj||function(){(h.hj.q=h.hj.q||[]).push(arguments)}; h._hjSettings={hjid:YOUR_ID,autoCapture:true}; a=o.getElementsByTagName('head')[0]; r=o.createElement('script');r.async=1; r.src=t+h._hjSettings.hjid+j; a.appendChild(r); })(window,document,'https://static.hotjar.com/c/hotjar-','.js?sv='); </script>
Make sure autoCapture:true is present – this flag enables auto‑tagging.
2. Verify Tagging in the Dashboard
- Go to Recordings → Filters → Events.
- Look for entries like
click:cta-buttonorscroll:75%.
3. Customize Tag Names (Optional)
If you need more descriptive names, add a data-hj-... attribute to the element:
<button data-hj-event="signup_submit">Sign Up</button>
Hotjar will use signup_submit instead of the generic click:button.
Best Practices for Using Auto‑Tag Events
- Limit clutter: Only add custom
data-hj-eventattributes where they add real value. - Combine with funnels: Use auto‑tags to build conversion funnels in Hotjar’s Funnels tool.
- Cross‑check with Google Analytics: Align Hotjar events with GA goals for a full picture.
- Regularly audit: Periodically review the event list to remove obsolete tags.
FAQ
Do I need to enable anything extra for auto‑tagging?
No. As long as the tracking code includes autoCapture:true, Hotjar tags standard interactions automatically.
Can I disable auto‑tagging for specific pages?
Yes. Add hjSettings={disableAutoTag:true} before the script on pages where you want full control.
Will auto‑tag events affect page performance?
Hotjar’s script is lightweight and runs asynchronously, so the impact on load time is negligible.
How do I view auto‑tag data in recordings?
Open a recording, click the Events tab, and you’ll see a timeline of all auto‑tagged interactions.
Is there a limit to the number of auto‑tags?
Hotjar caps the number of unique custom event names at 500 per site, but generic auto‑tags don’t count toward this limit.
Conclusion
Hotjar Auto‑Tag Events turn everyday clicks and scrolls into actionable data without a line of extra code. By understanding how they work, configuring the tracking script correctly, and following best practices, you can unlock deeper user insights and accelerate optimisation cycles.
Ready to supercharge your user research? Install Hotjar today, enable auto‑tagging, and start turning raw interactions into clear improvement opportunities.
Call to Action
Need help setting up Hotjar on a complex site? Contact our CRO team for a free audit and personalised tagging strategy.
Comments are closed, but trackbacks and pingbacks are open.