How to setup Amplitude
Guide about how to properly configure Amplitude.
Table of contents
Create an Amplitude account
- Go to https://amplitude.com/ and check their online demo to familiarise you a bit with the features and UI.
- Create an account
- Create a “[NRN] Staging” project. We recommend to use a different project per stage.
- We usually have one “Production” and one “Stating” versions, the staging version stores both development and staging events in order to keep the production database clean
- Create a “[NRN] Production” project
- Once your projects are created, go to “Manage data” (bottom left)
- Select your project
- Go to “Project settings”
- Copy the “API Key” value (not the secret!) and apply it to
NEXT_PUBLIC_AMPLITUDE_API_KEY
in.env
- If you have already configured Vercel, and if you want to deploy your app online, you must also configure Vercel secrets
vercel secrets add nrn-amplitude-api-key-staging YOUR_AMPLITUDE_STAGING_API_KEY
- (Optional) Get your “[NRN] Production” “API key” too, and run
vercel secrets add nrn-amplitude-api-key-production YOUR_AMPLITUDE_PRODUCTION_API_KEY
- This is only useful if you attempt to deploy to production
That’s it! Your Amplitude account is ready to use!