The easiest analytics
tool for Next.js

Nextract.js seamlessly adds free and privacy friendly web analytics to your Next.js app

Analytics without the hassle

Zero-config analytics in few lines of code

Why Nextract.js is better →

Privacy friendly

  • Analytics without cookies or tracking

  • Own your data - keep everything in your system

Unlike Google Analytics

Free forever

  • Absolutely free

  • 100% open source

Unlike Plausible Analytics

Easily self hosted

  • Self hosting as easy as it gets

  • Integrates with your Next.js app and does the rest by itself

Unlike Matomo Analytics

Fast & Lightweight

  • No external script needed

  • Bundled with your Next.js app served at once

Up and running in a minute

Install Nextract.js, connect to your database and you're set.

/pages/api/nextract/[...nextract].js

1 2 3 4 5 6 7 8 9 10 import Nextract from "nextract"; import PrismaDatabase from "@nextract/database-prisma"; import { PrismaClient } from "@prisma/client"; const client = new PrismaClient(); export default Nextract({ database: PrismaDatabase(client) });

/pages/app.jsx

1 2 3 4 5 6 7 8 9 import { NextractProvider } from "nextract/client"; export default function MyApp({ Component, pageProps }) { return ( <NextractProvider> <Component {...pageProps} />; </NextractProvider> ); }

/pages/app.jsx

1 2 3 import { Dashboard } from "nextract/client"; export default Dashboard();