Stars
Forks
Watchers
Developer links
Centrifugo
Benchmarked at one million concurrent WebSocket connections and 30 million delivered messages per minute on a single server, Centrifugo is a self-hosted real-time messaging server that integrates with any backend language — Node.js, Python, Go, Ruby, PHP, Java — without requiring architectural changes to your existing application. It handles persistent connections over WebSocket, HTTP-streaming, Server-Sent Events, gRPC, and experimental WebTransport, routing messages through a channel-based PUB/SUB model with automatic reconnection recovery that replays missed messages from hot channel history. Built-in horizontal scaling operates through Redis (including Redis Cluster, AWS ElastiCache, Valkey, KeyDB, and DragonflyDB), NATS, or PostgreSQL brokers, allowing multi-node deployments without external message queues. The server provides JWT-based authentication using HMAC or RSA keys, granular channel permissions, online presence tracking showing who is currently subscribed to a channel, and an RPC proxy that forwards client calls to your backend over HTTP or gRPC. The embedded ReactJS admin web interface displays real-time connection statistics, node information, and provides an interactive API console for publishing messages, managing subscriptions, and inspecting channel history. Official client SDKs are available for JavaScript, Dart, Go, Swift, and Java, with unidirectional transports requiring no SDK at all. Centrifugo also supports delta updates to minimize bandwidth, connection event proxying, and Prometheus-compatible metrics for Grafana monitoring. Running on a dedicated VPS on RepoCloud with guaranteed CPU, RAM, and SSD, full root SSH access, and a browser serial console. Apache 2.0 licensed.
Benefits
- Language-Agnostic Real-Time Layer
- Add real-time messaging to any backend language — Python, Node.js, Go, PHP, Java, Ruby — without rewriting your application architecture, using a simple HTTP or gRPC publish API.
- Million-Connection Single Server
- Benchmarked at one million concurrent WebSocket connections delivering 30 million messages per minute, with horizontal scaling via Redis Cluster, NATS, or PostgreSQL brokers.
- Automatic Message Recovery
- Hot channel history stores recent publications and automatically replays missed messages upon client reconnection, ensuring zero data loss during temporary network interruptions.
- Built-In Admin Dashboard
- Embedded ReactJS web interface displays real-time node statistics, connection counts, channel information, and provides an interactive console for publishing and managing subscriptions.
Features
- Multi-Transport Support
- Handle connections over WebSocket, HTTP-streaming, Server-Sent Events, gRPC, and WebTransport with automatic fallback, supporting both bidirectional and unidirectional communication modes.
- Channel PUB/SUB Model
- Subscribe clients to named channels with presence tracking, history retention, cache recovery mode, and delta updates to minimize bandwidth consumption.
- Scalable Broker Integration
- Scale horizontally across multiple nodes using Redis, Redis Cluster, AWS ElastiCache, Valkey, DragonflyDB, NATS, or PostgreSQL as the message broker layer.
- JWT Authentication
- Authenticate connections and channel subscriptions using HMAC or RSA-signed JSON Web Tokens, with granular permissions and proxy-based authorization to your backend.
- Prometheus Metrics
- Export connection counts, message rates, and node health metrics in Prometheus format for Grafana dashboards and alerting integration.