Documentation Index
Fetch the complete documentation index at: https://mintlify.com/vemetric/vemetric/llms.txt
Use this file to discover all available pages before exploring further.
Self-Hosting Overview
Vemetric is designed to be self-hosted, giving you complete control over your analytics data. This guide will help you deploy and manage your own Vemetric instance.Architecture
Vemetric is built as a modern monorepo using Bun and Turborepo, consisting of multiple microservices:App
The main web application (Vite SPA + Hono API) that provides the dashboard and API endpoints.
Hub
Event ingestion service that handles incoming analytics events from your websites and applications.
Worker
Background job processor that handles data aggregation, user enrichment, and email notifications.
BullBoard
Queue monitoring UI for debugging and managing background jobs.
Technology Stack
Vemetric uses a powerful combination of modern technologies:- Runtime: Bun 1.2.23
- Primary Database: PostgreSQL 17 with Prisma ORM
- Analytics Database: ClickHouse 23.10 for high-performance analytics queries
- Cache & Queue: Redis 7 with BullMQ for job processing
- Authentication: Better Auth for secure user authentication
- API Framework: Hono for fast, lightweight HTTP routing
Deployment Options
Docker Compose
Quick local development setup with all services preconfigured.
Kubernetes
Production-ready deployment with auto-scaling and high availability.
Manual Setup
Full control over individual service deployment and configuration.
Cloud Platforms
Deploy to AWS, GCP, Azure, or any cloud provider of your choice.
System Requirements
Minimum Requirements
- CPU: 2 cores
- RAM: 4 GB
- Storage: 20 GB SSD
- OS: Linux (Ubuntu 20.04+, Debian 11+, or similar)
Recommended Production Requirements
- CPU: 4+ cores
- RAM: 8+ GB
- Storage: 100+ GB SSD (depends on traffic volume)
- Network: Low latency connection between services
ClickHouse storage requirements scale with your analytics data. Plan for approximately 100-500 MB per million events, depending on your data retention policy.
Key Features
Data Privacy & Control
Data Privacy & Control
All analytics data stays on your infrastructure. You have complete control over data retention, backups, and access policies.
Scalability
Scalability
Each service can be scaled independently. ClickHouse handles billions of events efficiently, while Redis and BullMQ ensure reliable job processing.
Optional Integrations
Optional Integrations
Configure optional features like:
- Email notifications via Postmark
- Avatar uploads with S3-compatible storage (AWS S3, Cloudflare R2, MinIO)
- Payments via Paddle (if offering analytics as a service)
Observability
Observability
Built-in logging with Pino, BullBoard for queue monitoring, and optional Sentry integration for error tracking.
What’s Next?
Deployment
Get Vemetric up and running with Docker Compose or manual setup
Configuration
Configure environment variables and service settings
Architecture
Deep dive into system architecture and data flow
Database Setup
Learn about PostgreSQL and ClickHouse setup and migrations