About this project
Vercel Web Analytics is a privacy-friendly, real-time traffic insights package distributed as @vercel/analytics. It is designed for websites deployed to Vercel, including Next.js apps, and lets developers track page views as well as custom events.
Overview
The package automatically tracks all page views in an app. According to the README, it does not track data in development mode, so data is only gathered once a site is deployed.
Quickstart
The documented setup flow is short:
1. Enable Vercel Web Analytics for a project in the Vercel Dashboard.
2. Add the @vercel/analytics package to the project.
3. Inject the Analytics script into the app:
- For Next.js or React projects, use the Analytics component to inject the script.
- For other frameworks, use the inject function.
- For static sites that do not use npm, the documentation describes an alternative setup.
4. Deploy the app to Vercel and view incoming data.
Documentation
More details, including quickstart instructions, are linked from the project README to the official Vercel documentation for the analytics package.
Notes
The README presents the package as privacy-friendly and real-time, and the repository is published by Vercel. This description reflects only what the provided README states about automatic page view tracking, custom events, the absence of tracking in development mode, and the supported injection methods.
Comments
0 Rating appears after 10 ratings
Sign in to join the discussion.