The short answer
Analytiq works the same in every environment. Data appears on your dashboard as long as:
- Your code calls
init()with a valid API key - The device has internet access
Testing locally (recommended first step)
You don’t need to deploy your app to test Analytiq. Just run it locally:Do I need to push to GitHub and deploy first?
No. You do NOT need to:- Push to GitHub
- Deploy to Vercel / Netlify / Render
- Have a live production URL
- Your app running locally (
npm run dev) - Internet connection (the SDK sends events to Analytiq’s server over the internet)
Then why would I deploy?
You deploy for your users, not for Analytiq. Once your app is deployed and real users visit it, their events are automatically tracked too — no extra setup needed.Environment variables on Vercel / Netlify
When you deploy, your.env file is NOT uploaded to the hosting platform. You must add your environment variables manually in the hosting dashboard.
On Vercel:
- Go to your project on vercel.com
- Click Settings, then Environment Variables
- Add:
(Note: If using Next.js, name it
NEXT_PUBLIC_ANALYTIQ_KEYinstead) - Click Save, and Vercel redeploys automatically
- Go to your project on netlify.com
- Click Site Settings, then Environment variables
- Add:
(Note: If using Next.js, name it
NEXT_PUBLIC_ANALYTIQ_KEYinstead) - Trigger a new deploy
Why does local work but production doesn’t?
This is the most common issue after first deployment. The fix is almost always one of these:Separating local and production data
By default, all events from all environments go to the same project dashboard. If you want to keep local testing data separate from real production data, create two projects in Analytiq:- Project 1 — “My App (Development)”: use its API key in your
.envfor local development - Project 2 — “My App (Production)”: use its API key in your Vercel environment variables
Quick checklist before going live
- Events appear on dashboard in local testing
- API key added to Vercel/Netlify environment variables
- App redeployed after adding the env var
- Visited the production URL and checked dashboard for events
identify()called after login (if your app has users)reset()called on logout