Sending and receiving SMS messages at scale doesn’t require expensive cloud services. Whether you need two-factor authentication, marketing campaigns, transactional alerts, or a messaging API for your applications, self-hosted SMS gateways give you full control over costs, data, and routing.
In this guide, we compare three mature open-source SMS gateway platforms: TextBee, Jasmin, and Kalkun. Each takes a fundamentally different approach — from Android phone-based routing to enterprise SMPP infrastructure — so understanding their trade-offs is critical before you commit to one.
Why Self-Host an SMS Gateway?
Commercial SMS APIs like Twilio, MessageBird, and Vonage are convenient, but they come with significant drawbacks:
- Cost per message — Volume pricing still adds up quickly for high-throughput applications
- Vendor lock-in — Your messaging pipeline depends on a single provider’s API and uptime
- Data privacy — Message content, recipient lists, and delivery metadata flow through third-party servers
- Routing control — You cannot optimize for regional pricing or prefer specific carrier routes
A self-hosted SMS gateway solves these problems. You connect to SMPP providers, USB modems, or Android phones directly, route messages through your own infrastructure, and maintain complete visibility into every step of the pipeline. Combined with self-hosted live chat solutions and push notification servers, you can build an entire self-hosted messaging stack.
TextBee: Turn Any Android Phone into an SMS Gateway
TextBee (vernu/textbee) is the most popular open-source SMS gateway by GitHub stars, with over 2,500 stars and active development. Its unique approach: install a companion app on an Android phone, and that phone becomes your SMS modem.
Architecture
TextBee uses a modern TypeScript stack:
- API Server — NestJS REST API for sending/receiving messages
- Web Dashboard — Next.js frontend for management and analytics
- Android Companion — Runs on any Android device, handles actual SMS send/receive
- MongoDB — Message storage, user accounts, and device management
- redis — Message queue for high-throughput scenarios
Real-Time Stats (April 2026)
| Metric | Value |
|---|---|
| GitHub Stars | 2,529 |
| Primary Language | TypeScript |
| Last Updated | April 5, 2026 |
| Architecture | NestJS + Next.js + MongoDB + Redis |
| License | MIT |
docker Compose Deployment
TextBee provides an official docker-compose.yaml that spins up the full stack:
| |
Quick start:
| |
Sending SMS via API
| |
Best Use Cases
- Low-cost SMS for startups and small businesses
- Developers who already have spare Android phones
- Applications needing moderate SMS throughput (hundreds per day)
- Teams wanting a modern web dashboard out of the box
Jasmin: Enterprise-Grade SMPP SMS Gateway
Jasmin (jookies/jasmin) is the most mature and feature-rich open-source SMS gateway. Written in Python, it has been actively maintained for years and handles enterprise-scale SMS routing with advanced features like load balancing, failover, and billing.
Architecture
Jasmin is built around the SMPP (Short Message Peer-to-Peer) protocol:
- SMPP Server — Accepts connections from applications and upstream providers
- SMPP Client — Connects to upstream SMS aggregators and carriers
- Router — Intelligent message routing with MTR (message throughput rating), failover, and load balancing
- HTTP API — REST interface for sending SMS from web applications
- Redis — Session rabbitmqnt and queuing
- RabbitMQ — High-performance message broker for routing
Real-Time Stats (April 2026)
| Metric | Value |
|---|---|
| GitHub Stars | 1,171 |
| Primary Language | Python |
| Last Updated | April 17, 2026 |
| Architecture | Python + SMPP + Redis + RabbitMQ |
| License | Commercial (free trial available) |
Docker Compose Deployment
Jasmin’s docker-compose.yml (on the master branch) sets up the core services:
| |
Quick start:
| |
Configuring an SMPP Connector
Connect to Jasmin’s CLI (port 1401) and set up a connector to your upstream SMPP provider:
| |
Sending SMS via HTTP API
| |
Best Use Cases
- High-volume SMS routing (thousands to millions per day)
- Telecom operators and MVNOs
- Applications requiring SMPP protocol support
- Scenarios needing intelligent routing, load balancing, and failover
- Billing and accounting for SMS traffic
Kalkun: Web-Based SMS Manager with Gammu Backend
Kalkun (kalkun-sms/Kalkun) is a PHP-based web application that manages SMS through Gammu, an open-source library for communicating with GSM modems and phones. It provides a clean web interface for sending, receiving, and organizing SMS messages.
Architecture
Kalkun uses a traditional LAMP/LEMP stack:
- PHP Web Application — CodeIgniter-based frontend for SMS management
- Gammu — SMS daemon that communicates with GSM modems via serial/USB
- MySQL/MariaDB — Message storage and user management
- Gammu SMSD — Background daemon for continuous SMS monitoring
Real-Time Stats (April 2026)
| Metric | Value |
|---|---|
| GitHub Stars | 229 |
| Primary Language | PHP |
| Last Updated | February 18, 2026 |
| Architecture | PHP (CodeIgniter) + Gammu + MySQL |
| License | GPLv3 |
Manual Installation (No Docker Compose)
Kalkun does not provide an official Docker compose setup. Here is a standard installation on Ubuntu:
| |
Apache virtual host configuration:
| |
Best Use Cases
- Small-scale SMS management with a web interface
- Organizations already using USB GSM modems or dongles
- Users who prefer PHP-based applications on LAMP stacks
- Environments where a simple inbox/outbox workflow is sufficient
Feature Comparison
| Feature | TextBee | Jasmin | Kalkun |
|---|---|---|---|
| GitHub Stars | 2,529 | 1,171 | 229 |
| Language | TypeScript | Python | PHP |
| Protocol | Android API | SMPP | Gammu (AT commands) |
| Docker Support | Official compose | Official compose | Manual install |
| Web Dashboard | Next.js (built-in) | No (CLI/HTTP API) | CodeIgniter (built-in) |
| Message Queue | Redis | RabbitMQ | File-based / MySQL |
| Load Balancing | No | Yes (MTR routing) | No |
| Failover Routing | No | Yes | No |
| Billing | No | Yes | No |
| Multi-SIM | Yes (simSlot) | Yes (multiple connectors) | Yes (multiple modems) |
| HTTP API | REST (NestJS) | HTTP GET/POST | Web interface only |
| Database | MongoDB | Redis (runtime) | MySQL/MariaDB |
| License | MIT | Commercial | GPLv3 |
| Best For | Startups, developers | Telecom, enterprise | Small-scale, hobbyist |
Which Should You Choose?
Choose TextBee if:
- You want the easiest setup with a modern web dashboard
- You have Android phones available to use as modems
- Your SMS volume is moderate (hundreds per day)
- You prefer a fully Docker-deployable stack
Choose Jasmin if:
- You need enterprise-scale SMS routing and SMPP connectivity
- Your volume is high (thousands+ per day)
- You require intelligent routing, load balancing, and failover
- You need billing and accounting features
Choose Kalkun if:
- You already have GSM modems/dongles connected via USB
- You prefer a PHP-based web application
- Your use case is simple inbox/outbox management
- You are comfortable with manual LAMP stack configuration
FAQ
What is the difference between SMPP and GSM modem-based SMS gateways?
SMPP (Short Message Peer-to-Peer) is a telecom industry protocol used for high-volume SMS routing between applications and carriers. GSM modem-based gateways use AT commands sent over serial/USB connections to physical SIM cards. SMPP gateways like Jasmin handle thousands of messages per second and support carrier-grade features, while GSM modem solutions like Kalkun are simpler but limited by the physical modem’s throughput (typically 10-30 messages per minute).
Can I use TextBee without an Android phone?
No. TextBee’s core architecture requires the Android companion app to send and receive actual SMS messages. The server components (API, web dashboard, database) manage the routing and storage, but the physical SMS transmission happens through the Android device. If you need server-side SMS without a phone, consider Jasmin with an SMPP provider.
Does Jasmin have a free tier?
Jasmin is commercial software with a free trial available for evaluation. The trial provides full functionality for testing but is time-limited. For production use, you need to purchase a license. Check the jookies/jasmin repository for current pricing details.
Can Kalkun handle incoming SMS?
Yes. Kalkun monitors connected GSM modems through Gammu SMSD, which polls for new messages and stores them in the MySQL database. The web interface then displays them in an inbox view, similar to a traditional SMS messaging app. You can set up rules for automatic replies or forwarding.
How do I scale SMS throughput beyond a single device?
With TextBee, you can register multiple Android devices and distribute messages across them. With Jasmin, you configure multiple SMPP connectors and use the routing engine to load-balance across providers. With Kalkun, you can connect multiple GSM modems to the same Gammu instance. For the highest throughput, Jasmin with multiple SMPP upstream providers is the most scalable option.
Is it legal to self-host an SMS gateway?
Yes, self-hosting an SMS gateway is legal. However, you must comply with your country’s telecommunications regulations, including anti-spam laws (like the TCPA in the US or GDPR for EU recipients), opt-in/opt-out requirements, and any licensing requirements for operating as an SMS provider. Always consult local regulations before sending commercial or bulk SMS.
For related reading, see our guide to self-hosted live chat solutions and push notification servers. If you are building a complete messaging stack, also check our VoIP PBX comparison.