React
Analytics: Vercel vs self-hosted
Vercel Analytics takes ten minutes and sets no cookies. Umami and Plausible keep the data on your server. The choice depends on where the logs must live.
Key points
- Vercel Analytics is the shortest path when the site already sits on Vercel and page views plus Web Vitals are enough.
- Self-hosted means your database, your backups and your upgrades: the cost is maintenance.
- Vercel does not export raw events; Umami and Plausible do, if retention was configured first.
The choice between Vercel Analytics and a self-hosted tool depends on where the data must live, not on the feature count. If the site runs on Vercel and page views plus Core Web Vitals are enough, the native integration costs one line of code.
What each one measures
| Question | Vercel Analytics | Self-hosted |
|---|---|---|
| How many visits and from where | Yes, in aggregate | Yes, with sessions and paths |
| Real Core Web Vitals | Yes, field data | Only if you instrument them |
| Raw data export | No, aggregates only | Yes, from your database |
| Cookie banner | Not required | Depends on the setup |
| Cost at 100,000 visits | Included in the plan | VPS plus maintenance |
The minimum on Vercel
// app/layout.tsx
import { Analytics } from "@vercel/analytics/next";
import { SpeedInsights } from "@vercel/speed-insights/next";
export default function RootLayout({ children }: { children: React.ReactNode }) {
return (
{children}
);
}
The component writes to an endpoint that exists only on Vercel deployments. On a VPS the beacon has no destination and the dashboard stays empty: this is not a bug in the package.
The self-hosted minimum
docker run -d --name umami \
-p 3000:3000 \
-e DATABASE_URL=postgresql://umami:umami@db:5432/umami \
-e APP_SECRET=change-me \
ghcr.io/umami-software/umami:postgresql-latest
// app/layout.tsx
import Script from "next/script";
export default function RootLayout({ children }: { children: React.ReactNode }) {
return (
{children}
);
}
The honest comparison
- Umami ships under the MIT licence, Plausible under AGPL-3.0: reselling the service changes what the licence allows.
- Self-hosting means database backups, version upgrades and a written retention policy.
- Vercel filters bots for you and aggregates before it shows numbers, so you never see single events.
- With a self-hosted tool personal data stays inside your perimeter, but so does the obligation.
The limit nobody mentions
Vercel Analytics does not export raw events: if you later need a per-user cohort, that data is gone. Umami keeps it, but only if retention was configured on launch day.
For the reading dashboard the catalogue holds 1,556 blocks (1 November 2026): dashboard-01, the dashboard category and the charts in chart.
Where to go next
How to read real INP is in Core Web Vitals: INP. For the thresholds to wire into CI see Lighthouse CI; the comparison between a framework and a static generator for a marketing site is in Next.js vs Vite.
Frequently asked questions
Does Vercel Analytics use cookies?
No. It counts visits and Web Vitals with no cookie and no persistent identifier, so it usually needs no banner.
Can I use Vercel Analytics on a VPS?
Not without extra work. The package sends data to an endpoint available only on Vercel deployments; elsewhere you need your own proxy or another tool.
Umami or Plausible?
Umami if you want PostgreSQL and full control, Plausible if you prefer a finished product with managed hosting. Both are open source.
Do I lose campaign attribution with a self-hosted tool?
No, if you read UTM parameters from the URL. The tools named above store them by default, but check the configuration before launch.
What does it cost to keep it on a VPS?
A 2 GB instance covers 100,000 visits a month and costs a few euros. The real cost is upgrades, backups and database monitoring.