Trench
Open-source event tracking built on Kafka and ClickHouse
About Trench
Trench is open-source event tracking infrastructure built on Apache Kafka and ClickHouse, designed to handle large volumes of analytics events in real time. It provides a Segment-compatible API (Track, Identify, Group) that teams can self-host via a single Docker image or use as a managed cloud service. Built by the team behind Frigade (YC W23), it targets companies that need high-throughput, privacy-compliant analytics without the overhead of managing Kafka and ClickHouse separately.
Pros & Cons
Pros
- Genuinely open source under MIT license with no vendor lock-in
- Segment-compatible API enables drop-in replacement with minimal migration friction
- Proven ClickHouse + Kafka stack used by Airbnb, Datadog, and Spotify at scale
- Privacy-first and cookie-free with GDPR/PECR compliance out of the box
- Very generous free cloud tier with 1M events/month and 99.99% SLA
- Single Docker image dramatically simplifies deployment
Cons
- Very young project created in 2024 with small community and ecosystem
- No native visualization layer — requires a separate BI tool for dashboards
- Self-hosting Kafka + ClickHouse has real operational complexity for non-DevOps teams
- Fewer pre-built integrations compared to mature CDPs like Segment
- Cloud product and documentation are still evolving
Key Features
Segment API Compatibility
Drop-in replacement for Segment's Track, Identify, and Group calls with minimal migration
High-throughput Event Processing
Handles thousands of events per second on a single node powered by Kafka
Real-time SQL Queries
Query event data in real time via SQL or REST API
Single Docker Deployment
Entire stack ships as one Docker image with no separate Kafka/ClickHouse management
Webhook Destinations
Route events to external systems and data warehouses via webhooks
GDPR & PECR Compliance
Cookie-free architecture with built-in data access, rectification, and deletion controls
Serverless Autoscaling
Managed cloud tier scales automatically with a 99.99% SLA
Admin Dashboard & SQL Editor
Built-in UI for querying and managing event data on cloud tier
MIT Open Source License
Fully open-source, self-hostable on any cloud provider
Enterprise SSO & On-Premises
SAML 2.0 SSO and dedicated on-premises deployment for enterprise customers
Pricing
- Self-hosted
- Unlimited events
- Community support
- MIT license
- 1M free events per month
- $0.00003 per event after
- Admin dashboard
- SQL editor
- 99.99% SLA
- Serverless autoscaling
- Volume pricing
- Dedicated infrastructure
- Dedicated support engineer
- 24/7 phone/email
- On-premises option
- SAML 2.0 SSO
Best For
Product Analytics Backend
Replace Segment or Mixpanel's data pipeline with a self-hosted, cost-effective event store
Privacy-Compliant Event Tracking
Collect user behavior data without cookies for GDPR/PECR compliant EU-focused SaaS products
High-Volume Event Ingestion
Handle millions of events per day from mobile apps, web apps, or IoT devices without sampling
Data Warehouse Feeding
Stream real-time events into Snowflake, BigQuery, or Redshift via webhook destinations
Segment Migration
Migrate off Segment to reduce costs while maintaining API compatibility with minimal code changes
Similar Tools

Activepieces
Open-source, AI-first business automation

Tuta
Secure email with quantum-resistant encryption

Mailbox.org
Your data — under your control. Secure email and office from Germany

Posteo
Green, secure, simple, and ad-free email from Germany

Odoo
Modular open-source ERP for manufacturing & beyond

Cognism
Premium B2B contact data with GDPR-compliant EMEA coverage and Diamond Data