ActionLab Analytics for React
Add privacy-first, AI-powered analytics to your React site in under 60 seconds. No cookies, no consent banners, no complex setup.
Installation Code
React
<!-- Add to your public/index.html -->
<script
src="https://cdn.actionlabanalytics.com/actionlab.js"
data-site="YOUR_SITE_ID"
defer
></script>
<!-- Or dynamically in your App component -->
<!-- ActionLab auto-detects SPA route changes -->Step-by-Step Setup
- 1
Add the script tag to your public/index.html <head> section.
- 2
Replace YOUR_SITE_ID with your actual site ID.
- 3
ActionLab automatically detects React Router navigation.
- 4
No React component or hook needed — it just works.
Why Use ActionLab with React
- Automatic SPA route change detection
- No React components or hooks to maintain
- Works with React Router, Reach Router, and custom routing
- Zero bundle size impact — loaded externally
Frequently Asked Questions
Does ActionLab work with React SPAs?
Yes. ActionLab automatically detects client-side route changes using the History API and records them as pageviews. No additional configuration is needed for React Router or any other routing library.