Countly
Privacy-first, self-hosted analytics and customer engagement platform with full data ownership, GDPR compliance, and AI-powered insights across mobile, web, desktop, and IoT.
Countly is an open-source analytics and customer engagement platform built for organizations that require complete control over their data. It captures user behavior across mobile, web, desktop, and IoT applications while enforcing compliance with GDPR, CCPA, and HIPAA — eliminating the data-sharing risks inherent in third-party SaaS analytics tools.
At its core, Countly combines real-time dashboards, crash reporting, push notifications, remote configuration, and a compliance hub into a single self-hostable server. Its plugin-based architecture allows teams to enable or disable specific capabilities per application without touching the server codebase, making it practical for organizations running analytics at scale across multiple products and regulatory environments.
Countly offers three deployment tiers: Countly Lite (free, open-source, AGPL-3.0 with branding restrictions), Countly Enterprise (full feature suite with SLA and support, self-hosted or private cloud), and Countly Flex (fully managed SaaS with dedicated infrastructure). The server-side repository powering all editions is what you self-host, and the SDKs are identical across all tiers.
Built on Node.js and MongoDB with a Vue 3 frontend, Countly has accumulated over a decade of production deployment, more than 26,000 commits, and a weekly release cadence that reflects active commercial investment alongside its open-source community.
What You Get
- Session, View, and Event Tracking - Collects detailed user interaction data including session duration, screen views, and custom events across mobile, web, and desktop apps via 10+ official SDKs covering iOS, Android, React Native, Flutter, JavaScript, Unity, and more.
- Crash and Error Reporting - Automatically captures, groups, and analyzes crashes with full stack traces and device context for iOS, Android, React Native, Flutter, Node.js, Unity, Java, and JavaScript applications.
- Remote Configuration and Feature Flags - Dynamically modify app behavior, UI elements, and feature rollout percentages at runtime without requiring app store updates, supporting real-time A/B testing and progressive deployments.
- Push Notifications and In-App Messaging - Send targeted, behavior-triggered push notifications to iOS and Android users and display in-app content blocks without relying on third-party messaging infrastructure.
- Privacy and Compliance Hub - Centralized consent collection, data subject request handling, user data export, and anonymization tools that satisfy GDPR Article 17, CCPA deletion rights, and HIPAA data governance requirements.
- AI-Powered Analytics and Insights - Automated report generation, dashboard recommendations, and behavioral anomaly detection built into the platform, with first-class LLM interaction tracking for AI-powered product telemetry.
- Custom Dashboards and Reporting - Drag-and-drop dashboard builder supporting time-series charts, funnel analysis, cohort comparisons, and retention grids with scheduled email delivery and alert rules.
- Webhooks, Hooks, and REST APIs - Export analytics events and trigger workflows via outbound webhooks, use the full read/write REST API to integrate with internal data warehouses, CRM systems, or BI tools.
- Plugin-Based Extensibility - Enable, disable, or build plugins per application instance at runtime, covering capabilities from user journey analysis and A/B testing to density maps and time-of-day visualizations.
Common Use Cases
- Privacy-compliant mobile analytics for regulated industries - A digital health company deploys Countly on-premises to collect patient app usage data, using the Compliance Hub to handle HIPAA data subject requests and consent revocations without exporting data to third parties.
- Multi-platform product analytics without vendor lock-in - A SaaS company runs Countly to unify event data from its web app, mobile clients, and desktop agent into a single dashboard, using remote configuration to roll out features progressively across platforms.
- AI product telemetry and LLM usage tracking - A product team instruments their AI assistant with Countly’s LLM interaction events to measure tool call rates, model response quality scores, and user feedback signals alongside standard engagement metrics.
- Enterprise analytics consolidation behind the firewall - A financial services firm self-hosts Countly on a private cloud to aggregate analytics from 12 internal applications, using role-based access control to give each product team isolated visibility into their own app data.
- Mobile crash monitoring with automated alerting - A game studio uses Countly’s crash reporting to detect regressions within hours of each release, with email alerts and hooks pushing critical crashes to their incident management system.
Under The Hood
Architecture Countly uses a layered, plugin-first architecture where an Express-based API layer — distributed across Node.js cluster master and worker processes — handles request ingestion, while a dedicated plugin manager acts as the extensibility backbone connecting frontend, API, and data layers through lifecycle hooks and event emission. The plugin system enforces a standardized contract per feature (install, API, and frontend directories) and allows capabilities to be toggled per application instance at runtime without server restarts. Database writes are deliberately decoupled from request ingestion via a three-tier batcher system — WriteBatcher, ReadBatcher, and InsertBatcher — each of which auto-adjusts its flush period based on server load to prevent MongoDB throughput degradation under heavy traffic. An optional second MongoDB connection handles high-volume drill queries in isolation, keeping operational data reads unaffected by analytics aggregation workloads.
Tech Stack The backend runs on Node.js with Express handling HTTP routing, using Bluebird for promise-based async flow and MongoDB as the sole data store, with GridFS managing binary file storage for reports and exported data. The frontend combines Vue 3 components with Handlebars templates for legacy compatibility, compiled through a Grunt-based build pipeline that also handles ESLint enforcement and test orchestration. Docker Compose orchestrates nginx, MongoDB, and multiple Countly service containers across Ubuntu and CentOS base images, while runit provides supervision for individual services inside containers. TypeScript declaration files annotate core modules — requestProcessor, batcher, rights, and pluginManager — for editor tooling without requiring a full TypeScript compilation step across the codebase. Husky enforces pre-commit ESLint checks on JavaScript and Vue files via lint-staged, with Mocha and Supertest driving HTTP integration tests and nyc measuring coverage.
Code Quality The test suite is organized into numbered integration test suites covering frontend authentication, API write flows, API read validation, and plugin-specific scenarios, with Supertest issuing real HTTP requests against a live MongoDB instance to validate end-to-end behavior. Core API modules carry comprehensive JSDoc annotations — requestProcessor, rights, and batcher include complete parameter and return type documentation — and the TypeScript declaration files provide structured type information for the most critical abstractions. ESLint with the Stylistic plugin runs on every commit via pre-commit hooks and on every pull request via GitHub Actions CI, with separate rule configurations for Vue and JavaScript files. Error handling is inconsistent across the plugin layer: core modules use structured logging via a dedicated log utility, while older plugins return raw string errors without context. The parallel use of callbacks and Promises within the same modules is an artifact of incremental modernization, reducing readability in plugin code that predates the Bluebird adoption.
What Makes It Unique Countly’s runtime plugin toggle — enabling or disabling analytics capabilities per application without server restarts — is a production-grade flexibility not commonly found in open-source analytics platforms. The adaptive database batcher that self-tunes flush intervals under load is a concrete engineering solution to the throughput bottleneck that typically forces self-hosters to shard or cache writes externally. The compliance hub treating consent collection, data subject requests, and anonymization as native analytics primitives rather than bolt-on integrations reflects over a decade of operating in regulated environments. Most distinctively, Countly has introduced first-class LLM interaction tracking events — capturing tool calls, model responses, user feedback, and parameter usage — positioning it as one of the few open-source platforms with native telemetry support for AI-powered products.
Self-Hosting
Countly is licensed under AGPL-3.0 with a modified Section 7 that adds significant branding restrictions on top of the copyleft base. The AGPL copyleft clause requires that any modified version you run as a network service must have its source code made available to users — a meaningful constraint for organizations planning to build proprietary analytics features on top of the platform. The additional Section 7 terms prohibit removing, replacing, or obscuring any Countly logo, branding, or name from the user interface, source code, or any publicly visible screen, and bar the use of other brands on derivative products. Commercially, this means you can self-host and use Countly Lite freely for internal purposes, but you cannot white-label it, strip the branding, or offer it as a hosted service to third parties without negotiating a commercial license.
Running Countly yourself requires a Linux server (Ubuntu or CentOS are supported by the installation script) with MongoDB, Node.js, and nginx configured. The provided Docker Compose setup simplifies local and production deployment, but you remain responsible for MongoDB performance tuning, storage capacity as event volume grows, TLS certificate management, backup schedules, and version upgrades — all of which require engineering attention at scale. The weekly release cadence means staying current involves regular upgrade operations using the provided upgrade scripts, and skipping multiple releases increases the complexity of catching up. Infrastructure requirements grow substantially with event volume: MongoDB needs appropriate indexing, memory, and disk provisioning for time-series analytics collections, and the drill database for deep user-level queries benefits from dedicated resources.
Compared to Countly Flex (the managed SaaS tier), self-hosting gives up region-redundant infrastructure, automated backups, managed upgrades, and Countly’s direct engineering support under an SLA. Countly Enterprise adds advanced features — granular permissions, deeper drill capabilities, cohort targeting, and extended engagement tools — that are not included in the open-source Lite edition; the exact feature boundary between Lite and Enterprise is documented on the pricing page rather than being obvious from the repository alone. For organizations without dedicated infrastructure engineers, the Flex managed option removes operational burden while preserving the data residency controls that make Countly attractive over commodity SaaS analytics.
Related Apps
Grafana
Monitoring · Analytics
The open-source observability platform that unifies metrics, logs, and traces from any data source into dynamic, queryable dashboards.
Grafana
AGPL 3.0OpenBB
Databases · Analytics · Invoicing Finance
The AI Workspace for Finance: Connect Data, Run AI Agents, Build Analytics
OpenBB
OtherClickHouse
Databases · Analytics · Data Engineering
Open-source column-oriented database that delivers real-time analytical queries on petabyte-scale data with millisecond latency.