MetricRaven

Buyer's guide · Developer analytics

The 8 best analytics tools for Next.js apps in 2026

Prices and features checked on each tool's website · sources

On Vercel, Vercel Web Analytics is the zero-effort start. For simple, light, cookie-free stats, Plausible, Fathom or Simple Analytics (which ships an official Next.js plugin with a built-in proxy). For product analytics with server events and replay, PostHog. If you want to see which traffic source brings paying customers, MetricRaven loads with next/script, proxies through one route handler or one DNS record, and reads payments from Stripe and other providers on the server.

What a Next.js app needs from analytics

Next.js apps are mostly single-page apps after the first load, with work split between the browser, server components, route handlers and server actions. Analytics has to follow client-side navigation (<Link> and router.push don't reload the page), stay out of the way of hydration, and ideally record what only the server knows: a sign-up that succeeded, a payment that cleared.

Ad blockers are the other developer problem. Developer and tech audiences block third-party analytics domains more than most, so a tool that can be served from your own domain through a rewrite, a route handler or a CNAME keeps more of your data. Our guide to stop ad blockers losing data explains the trade-offs.

What to compare as a developer

  • Install effort

    An official package or a documented next/script snippet for the App Router, with route changes tracked without your own listener.

  • Script weight

    Sizes vary several-fold. Compare what each vendor states, and remember optional features (replay, heatmaps) usually load extra code.

  • Server-side events

    Server actions and webhooks know things the browser doesn't. Look for an events API or SDK, and how it links a server event to the visitor who caused it (server-side tracking).

  • First-party proxy

    A documented Next.js rewrite or route handler, or a managed custom domain, so requests go to your own origin. Check which plan includes it.

Next.js analytics tools compared

Entry prices for the smallest paid tier, in the currency each tool's pricing page lists.

Tools compared by best use, price, trial, sign-up and revenue tracking
Vercel Web AnalyticsBest forApps hosted on Vercel that want analytics with no setupStarting priceFree 50k events; Pro $0.03/1KFree plan or trialHobby free; Pro trial 14 daysHow you startVercel dashboardRevenue trackingNone
MetricRavenBest forSaaS and indie apps that want revenue by traffic sourceStarting price$9/month (10k events)Free plan or trial14 days, no cardHow you startSelf-serveRevenue trackingPayment providers connected; first touch
PostHogBest forProduct engineers who want analytics, replay and flags with server eventsStarting priceFree; then usage-basedFree plan or trialFree plan, no cardHow you startSelf-serve or self-hostRevenue trackingStripe via data warehouse
PlausibleBest forDevelopers who want the lightest well-known scriptStarting price$9/month (10k pageviews)Free plan or trial30 days, no cardHow you startSelf-serveRevenue trackingRevenue goals you send; Business plan
UmamiBest forOpen-source fans who want to self-host or stay freeStarting priceFree; Pro $20/month (1M events)Free plan or trialFree plan; 14 days on paidHow you startSelf-serve or self-hostRevenue trackingRevenue events; payments on Pro
Simple AnalyticsBest forPrivacy-first teams that want an official Next.js pluginStarting priceFree; $15/month (20k)Free plan or trialFree plan; 14 days, no cardHow you startSelf-serveRevenue trackingNone documented
FathomBest forAgencies running many small Next.js sitesStarting price$15/month (100k pageviews)Free plan or trial7 days, card requiredHow you startSelf-serveRevenue trackingEvent values you send
Google Analytics 4Best forApps that need Google Ads conversions and audiencesStarting priceFreeFree plan or trialFreeHow you startSelf-serveRevenue trackingEcommerce events you implement

1. Vercel Web Analytics

Best for: Apps hosted on Vercel that want analytics with no setup

Vercel Web Analytics is the shortest path on Vercel: enable it, add <Analytics /> to your root layout and deploy. Requests are first-party by default because they go to your own deployment.

It answers traffic questions only: custom events need Pro, and there are no revenue reports.

Key features

  • The official @vercel/analytics package: enable it in the dashboard, then add <Analytics /> from @vercel/analytics/next to app/layout.tsx.
  • First-party by default: after the next deploy, the script and endpoints are served from your own deployment under /_vercel/insights/*.
  • Server-side custom events with track() from @vercel/analytics/server in route handlers and server actions (Pro and Enterprise).

Pricing

Hobby includes 50,000 events a month with one month of reporting. Pro charges $0.03 per 1K events on top of the Pro plan, with 12 months of data; Web Analytics Plus adds $10 a month per team for 24 months and UTM parameters.

Limitations

  • Set up through a Vercel project and deployment; its docs don't describe using it on other hosts.
  • Custom events are Pro and Enterprise only, with 2 properties per event on Pro and no nested objects.
  • No revenue reports or payment connections.

Visit Vercel Web Analytics

2. MetricRaven

Best for: SaaS and indie apps that want revenue by traffic source

MetricRaven installs with next/script in app/layout.tsx (Next.js guide) or with the typed @metricraven/web package, follows <Link> navigation on its own, and connects your payment provider on the server. Each payment is credited to the visit that first brought the customer.

The script is heavier than the minimal trackers here, and it has no free plan. The SaaS analytics roundup compares it with product analytics tools.

Key features

  • Install with next/script (App Router or Pages Router) or the dependency-free @metricraven/web package with typed track, identify and consent calls, safe to import during server rendering.
  • One tracker of about 20 KB minified (about 8 KB gzipped); page speed, automatic events, error tracking and replay are separate add-ons that load only when you switch them on.
  • Server events from route handlers and server actions with @metricraven/node, which runs on Node, Bun, Deno, Cloudflare Workers and Vercel Edge.
  • A Next.js route handler proxy or a managed proxy with one CNAME record, both on every plan.
  • Stripe, Paddle, Lemon Squeezy, Polar and other providers connected server-side, so payments, renewals and refunds reach the first visit, with MRR and revenue by channel.

Pricing

Starter is $9 a month for 10k events and $19 for 100k; Growth is $19 and $39, with up to 30 websites, team members, AI visibility and replays of pricing and checkout visits. Revenue attribution is on both plans. Yearly billing costs ten months' price (pricing).

Limitations

  • Its script is several times larger than Plausible's or Fathom's, because the base tracker includes consent handling, cross-domain linking and goal capture.
  • One attribution model (first touch), no product analytics such as retention cohorts or feature flags, no free plan and no self-hosting.

Start a 14-day free trialSee pricing

3. PostHog

Best for: Product engineers who want analytics, replay and flags with server events

PostHog has official client and server libraries for Next.js and an official rewrites guide for proxying. It's the most complete toolkit here, with a 1M-event free tier.

Revenue analytics (Stripe through its warehouse) is in beta and links customers manually, so revenue by channel means writing queries.

Key features

  • posthog-js initialized in instrumentation-client, plus a setup wizard (npx @posthog/wizard).
  • Server-side capture with posthog-node in route handlers and server actions.
  • An official Next.js rewrites guide for a first-party proxy, and a managed reverse proxy free on PostHog Cloud.
  • Product analytics, web analytics, session replay, feature flags, experiments and surveys.

Pricing

Free up to 1M product analytics events and 5,000 recordings a month. After that you pay per unit, from $0.00005 an event, with no per-seat charges.

Limitations

  • PostHog warns some hosts modify headers during rewrites, causing 503 or 400 errors, and proxied traffic runs through your server.
  • Revenue analytics is in beta; Stripe customers must be linked to people by hand.

Visit PostHog

4. Plausible

Best for: Developers who want the lightest well-known script

Plausible's script is about 2.5 KB by its own count, and its Events API takes server-side events, including revenue. Next.js support comes through next-plausible, a community package Plausible documents.

Revenue is a Business plan feature, and a managed proxy is Enterprise only, so you proxy through next-plausible yourself.

Key features

  • A 2.5 KB script, by Plausible's comparison with Google Analytics.
  • Next.js setup with the community next-plausible package, which Plausible's docs link and which supports proxying.
  • A server-side Events API that takes a revenue amount and currency.
  • Cookie-free, EU-hosted and open source (AGPL Community Edition).

Pricing

Three plans priced by pageviews. At 10k pageviews Starter is $9, Growth $14 and Business $19 a month. Funnels and revenue goals are on Business. 30-day trial, no card.

Limitations

  • Revenue tracking and funnels are on the Business plan.
  • The managed proxy is Enterprise only, and Plausible says payment webhooks aren't suitable for its Events API because they don't carry the visitor's headers.

Visit PlausibleMetricRaven vs Plausible

5. Umami

Best for: Open-source fans who want to self-host or stay free

Umami is MIT-licensed, free to self-host and free in the cloud up to 100k events. Its docs install it with next/script and send server events with @umami/node.

For proxying, the docs point at Next.js rewrites without code, and renaming the script and endpoint is for self-hosted installs.

Key features

  • Install with next/script per Umami's docs; no Next.js package needed.
  • Server-side events through /api/send or the official @umami/node client.
  • Revenue, attribution and funnel reports on every cloud plan, with payment integrations on Pro and Business.
  • MIT license and free self-hosting.

Pricing

Hobby is free for 100k events and one website. Pro is $20 a month for 1M events and 20 websites; Business is $200 for 10M. Self-hosting is free.

Limitations

  • No Next.js proxy code in its docs, and script and endpoint renaming is self-hosted only.
  • The free cloud plan covers one website and six months of data.

Visit UmamiMetricRaven vs Umami

6. Simple Analytics

Best for: Privacy-first teams that want an official Next.js plugin

Simple Analytics ships @simpleanalytics/next, an official plugin that proxies requests through your app and can track events from server actions and route handlers.

Its standard script is 4.7 KB gzipped, with a 2.0 KB light version. It has no revenue reports.

Key features

  • An official @simpleanalytics/next plugin: wrap your config, add a component to the root layout.
  • Requests proxied through your app by the plugin, so ad blockers see your own domain.
  • trackEvent in server actions and route handlers, and server-side pageviews (middleware tracking is experimental).
  • No cookies, no IP addresses and no visitor profiles.

Pricing

A Free plan for 5 websites with 30 days of history. The paid Simple plan is $15 a month for 20k pageviews and events, $20 for 100k and $60 for 1M, with 10 websites. 14-day trial, no card.

Limitations

  • No revenue or attribution reports.
  • The free plan keeps one month of history and requires a badge.

Visit Simple AnalyticsMetricRaven vs Simple Analytics

7. Fathom

Best for: Agencies running many small Next.js sites

Fathom's script is about 2 kB, and its docs show an App Router setup with fathom-client, a community package. Event values with the first referrer seen cover simple revenue.

Custom domains are no longer offered, there's no server-side event API in its docs, and the trial needs a card.

Key features

  • A 2 kB script, by Fathom's own count.
  • App Router setup in its docs using the community fathom-client package.
  • Event values credited to the first referrer or UTM seen, on every plan.
  • At least 50 sites on one plan, cookieless.

Pricing

One plan priced by pageviews: $15 a month for 100k, $25 for 200k and $60 for 1M. No free plan; the 7-day trial needs a card.

Limitations

  • No proxy or custom domain option since 2023.
  • Events are sent from the browser only, and the 7-day trial needs a card.

Visit FathomMetricRaven vs Fathom

8. Google Analytics 4

Best for: Apps that need Google Ads conversions and audiences

Next.js documents a <GoogleAnalytics> component in @next/third-parties, and GA4's Measurement Protocol takes server events.

The package is experimental, server events need the browser tag to make full reports, and GA4 needs a consent banner in the EU and UK.

Key features

  • <GoogleAnalytics gaId> from @next/third-parties in your root layout, and sendGAEvent for client events.
  • Server events with the Measurement Protocol (/mp/collect), joined to a session when you pass its client and session IDs.
  • Free, with links to Google Ads, Search Console and BigQuery.

Pricing

Free. Analytics 360 for large enterprises is sold through Google's sales team with no public price.

Limitations

  • Next.js labels @next/third-parties experimental, and route-change pageviews rely on GA's enhanced measurement setting.
  • Google says the Measurement Protocol augments the tag rather than replacing it; events sent only that way give partial reports.

Visit Google Analytics 4MetricRaven vs Google Analytics 4

How to choose analytics for your Next.js app

  • You deploy on Vercel and want traffic stats today

    Vercel Web Analytics: Enable, add one component, deploy.

  • You need revenue and MRR by traffic source

    MetricRaven: Payments from your provider, credited to the first visit, with a Next.js proxy on every plan.

  • You want product analytics, replay and flags

    PostHog: Official client and server libraries and a rewrites guide.

  • Script weight comes first

    Plausible: About 2.5 KB, with a server Events API.

  • You want an official plugin with a built-in proxy and no revenue needs

    Simple Analytics: @simpleanalytics/next proxies through your app.

  • You want to self-host for free

    Umami: MIT license, next/script install and a Node client.

The bottom line

For most Next.js apps the install is the easy part: every tool here is one component or one next/script tag in the root layout. The differences are in what happens next. Can you send events from server actions? Can you serve it from your own domain without writing a proxy? And can it tell you which traffic paid, or only which traffic arrived?

If the app makes money, wire the payment side first and the dashboard second. With MetricRaven that means passing the visitor ID to Stripe Checkout and calling identify when users sign in, so payments and renewals land on the channel that brought them.

Frequently asked questions

What is the best analytics for Next.js?

On Vercel, Vercel Web Analytics needs the least setup. For light, cookie-free stats, Plausible, Fathom or Simple Analytics. For product analytics, PostHog. For revenue by traffic source from your payment provider, MetricRaven.

How do I add analytics to the Next.js App Router?

Add the tool's script with next/script or its component in app/layout.tsx so it loads once for every page. Client-side navigation changes the URL through the history API, which most trackers follow without extra code.

How do I stop ad blockers blocking analytics in Next.js?

Serve the script and events from your own domain: a rewrite or route handler in your app, or a managed custom domain. PostHog, Simple Analytics and MetricRaven document this for Next.js.

Can I track events from Next.js server actions?

Yes, with a server SDK or events API: Vercel's server track on Pro, posthog-node, @umami/node, Plausible's Events API, Simple Analytics' plugin, GA4's Measurement Protocol or @metricraven/node.

Sources and method

Every competitor fact comes from that company's own website, checked on the date shown. Where we couldn't confirm something, we left it out. MetricRaven details come from our pricing and docs. We make MetricRaven, so weigh our placement accordingly. Spotted something out of date? Email support@metricraven.com.

Vercel Web Analytics · checked Nov 24, 2026

PostHog · checked Nov 24, 2026

Plausible · checked Nov 18, 2026

More roundups

All posts

See which traffic actually pays

Track revenue by channel, campaign and page automatically, from your real payments.

14-day free trial, no card required.