Self-hosted, privacy-first web analytics platform — the dashboard and ingestion service that powers the
@indeks/* SDK.
Indeks is the dashboard + ingestion backend you self-host to receive, store, and visualize events sent
by the Indeks SDK (@indeks/core, @indeks/react). Events land in
ClickHouse for fast analytical queries, while app data — users, projects, auth — lives in Postgres.
| Layer | Tech |
|---|---|
| Dashboard UI | Next.js 16 (Turbopack), Tailwind v4, Radix UI / Base UI, lucide-react |
| Ingestion API | Elysia (@elysiajs/cors, @elysiajs/openapi) |
| Event storage | ClickHouse (@clickhouse/client) |
| App data | PostgreSQL via Neon (@neondatabase/serverless) + Drizzle ORM |
| Auth | better-auth |
| Plunk, React Email, Nodemailer | |
| Live visitor view | cobe (interactive globe) |
Events captured by the SDK are processed by the ingestion service and persisted to the database — see
indeks.md for the full event schema (clicks, scrolls, sessions, rage clicks, form
abandonment, performance metrics, and more).
- Bun
- A PostgreSQL database (Neon recommended)
- A ClickHouse instance
git clone https://github.com/ru-dr/indeks.git
cd indeks
bun installCreate a .env in the project root. At minimum you'll need credentials for:
# Postgres (app data — users, projects, sessions)
DATABASE_URL=
# ClickHouse (event storage)
CLICKHOUSE_URL=
CLICKHOUSE_USER=
CLICKHOUSE_PASSWORD=
# Auth
BETTER_AUTH_SECRET=
# Email (Plunk)
PLUNK_API_KEY=
Exact variable names should match what's read in your config/auth setup — adjust these to whatever your code actually expects.
bun run dev # start dev server (Turbopack)
bun run build # production build
bun run start # start production server
bun run check # typecheck + lint
bun run lint # lint onlyOpen http://localhost:3000.
Schema is managed with Drizzle (drizzle.config.ts). Use the Drizzle Kit CLI
directly for generating/running migrations, e.g.:
bunx drizzle-kit generate
bunx drizzle-kit migrateFull documentation of every event type and its payload — base event fields, device data, session events,
rage/frustration detection, form events, performance metrics, and custom events — lives in
indeks.md.
Indeks is self-hosted by design: your event data stays in your own ClickHouse and Postgres instances. Nothing is sent to a third party.
indeks-sdk—@indeks/core,@indeks/react,@indeks/shared, the client SDK that sends events to this platform.
Includes a vercel.json — deployable to Vercel out of the box for the Next.js app.
ClickHouse and Postgres should be hosted separately.
No license file is currently set on this repo. Add a LICENSE to make the terms explicit (the SDK repo
uses MIT, for reference).