Litlyx is an open-source, self-hostable web analytics tool designed for developers, marketers, and privacy-conscious businesses seeking a clean alternative to Google Analytics, Plausible, and Matomo. It provides real-time visitor tracking, custom event monitoring, and AI-powered data insights without relying on cookies or third-party tracking. Built with TypeScript and compatible with React, Next.js, Vue, Nuxt, and WordPress, Litlyx offers both cloud-hosted and Docker-based self-hosting options for full data control.
The platform uses a lightweight JavaScript SDK that integrates via a single script tag or npm package, with a backend powered by Node.js and a dashboard built on modern web frameworks. Data is processed and stored in EU-based infrastructure, ensuring full GDPR compliance. Users can deploy Litlyx in under 30 seconds using Docker or use the hosted cloud version with zero infrastructure management.
What You Get
- Cookie-Free Analytics - Tracks visitors without cookies, scripts, or consent banners, fully compliant with GDPR and privacy regulations.
- AI-Powered Insights - AI assistant analyzes traffic trends, campaigns, and user behavior to deliver actionable insights without manual reporting.
- Custom Event Tracking - Track any click, button, or function with simple API calls like Lit.event(‘click_on_buy_item’, { metadata: {…} })
- Universal Integration - Works with any website via script tag, npm/pnpm, or WordPress plugins; supports React, Next.js, Vue, Nuxt, and Angular.
- Self-Hosting with Docker - Fully deployable on-premises using docker-compose; data stays in your infrastructure with no vendor lock-in.
- Real-Time Dashboard - Live metrics for visits, unique visitors, bounce rate, session duration, and page views with interactive trend charts.
Common Use Cases
- Running a GDPR-compliant blog - A blogger uses Litlyx to track traffic without cookie banners, ensuring legal compliance while gaining real-time reader insights.
- Managing multiple client websites - A web agency deploys Litlyx across client sites using a single script tag, offering clean, branded reports without third-party tracking.
- Tracking product conversions - A SaaS startup tracks custom events like ‘click_on_pricing’ or ‘download_whitepaper’ to measure marketing funnel performance.
- Self-hosting analytics for privacy-sensitive industries - A healthcare or finance company hosts Litlyx internally to avoid data leaving the EU and comply with strict data residency laws.
Under The Hood
Architecture
- Monolithic internal structure within Docker services, lacking clear modularity or separation of concerns between transport, business logic, and data access layers
- Tight coupling between TRPC API contracts and domain logic, with no dependency injection or inversion of control patterns
- Direct references to Redis and MongoDB across services without repository or adapter abstractions, reducing testability and flexibility
- Duplicate implementations of session handling, data access, and state management between Vue dashboard and Express-based services
- AI and sidebar components tightly coupled to UI rendering, with no service-layer abstraction for data fetching or state management
Tech Stack
- Node.js backend powered by Express and tRPC for type-safe routing, paired with Mongoose for MongoDB persistence
- Vue 3 and Nuxt 3 for the dashboard, leveraging VueUse, Reka UI, and Lucide Vue for component utilities and icon system
- Redis for session and caching, orchestrated via Docker Compose alongside producer and consumer services
- TypeScript-first approach with Zod for runtime validation and Stripe SDK for payment processing
- Build and deployment managed through pnpm and custom ts-node scripts for image building and environment configuration
Code Quality
- Limited testing with many functions lacking assertions, indicating weak test coverage and poor discipline in verification
- Business logic entangled in route handlers and component files, with no clear modular boundaries
- Superficial error handling using generic try-catch blocks, lacking custom error classes, structured logging, or client-friendly error propagation
- Inconsistent naming conventions across files and variables, with no defined standard
- Absence of linting or static analysis tooling, allowing code smells and style violations to persist undetected
What Makes It Unique
- Component-driven UI with Class Variance Authority (CVA) enabling type-safe, design-consistent components at the framework level
- Reactive project membership system with real-time invite handling and role-based UI rendering tightly integrated with auth and state
- Server-side scheduled aggregations via Nuxt 3 API routes, eliminating external cron dependencies
- Dynamic sidebar architecture that adapts to user plan status and project ownership, delivering personalized navigation without external libraries
- Type-safe integration of Lucide icons with Vue 3 composition API, minimizing boilerplate while maximizing scalability
- Unified error handling composable (useCatch) that consolidates toast notifications, async recovery, and state refresh into a single reusable pattern