Documentation

Docs

Everything you need to embed tracking, track custom events, and self-host IROTECHLAB ANALYTICS.

Install the tracking script

Grab your site key from the dashboard, then paste this one line into the <head> of every page you want to track.

<script defer
  data-site="iro_site_xxxxxxxxxxxx"
  src="https://irotechlab-analytics.netlify.app/script.js"
></script>

That's it — pageviews start flowing immediately.

Custom events

Track anything with window.iro.track(). The script exposes this global once loaded.

// Track any custom event
window.iro.track('signup_complete', { plan: 'pro' });
window.iro.track('checkout_started', { amount: 29 });

Single-page apps

No config needed. The script hooks into pushState, popstate, and hashchange automatically.

// Single-page apps: the script auto-detects
// pushState / popstate / hashchange. Nothing to do.

Collection API

You can also POST directly if you prefer sending events server-side.

GET https://irotechlab-analytics.netlify.app/api/collect
  ?site=iro_site_xxxxxxxxxxxx
  &path=%2Fpage
  &ref=https%3A%2F%2Fgoogle.com
  &type=pageview

// Or POST (used by script.js sendBeacon):
{
  "site": "iro_site_xxxxxxxxxxxx",
  "path": "/page",
  "ref": "https://google.com",
  "type": "pageview"
}

Self-hosting

Full instructions live on the GitHub repo.

  1. Clone the repo
  2. Register your own app at irotechlab-auth.netlify.app/developer
  3. Create a Postgres database (Neon, Supabase, RDS, etc.)
  4. Set env vars in .env.local
  5. Run npm run db:push then npm run dev
Full self-host guide on GitHub →

What we collect

  • ✅ Page path, referrer host, timestamp
  • ✅ Country (from CDN header, not stored IP)
  • ✅ Device type, browser, OS (from user agent)
  • ✅ Screen size bucket, language
  • ✅ UTM parameters
  • ❌ No cookies
  • ❌ No IP addresses stored
  • ❌ No cross-site tracking
  • ❌ No personal identifiers

Visitor IDs are derived by hashing IP + user agent + date, and rotate every 24 hours. No personal data is ever persisted.

Still stuck? Back to home or message us on telegram: @ironmanhindigaming or instagram: @ironmanyt00