Hi, we're the team behind textbee, an open-source SMS gateway.
Your app makes one HTTP request. A text goes out from an Android phone you already own, through its SIM, from its number. Replies come back to your server as webhooks. More than 40,000 developers have signed up so far, and the whole thing is MIT licensed.
This post explains why we built it on phones, how a message travels, and what we learned from running SMS on real devices.
Why a phone?
Sending SMS from an app usually means renting a number from a cloud provider, paying for every message, and in some countries filling in registration forms before the first text goes out.
Meanwhile, most of us carry a phone with a plan that already covers texting. textbee puts that phone to work. It fits:
- login codes for a side project
- appointment reminders from the number your customers already saved
- server and home lab alerts
- two-way texting, where customers reply to a real number
How a message travels
- Your code calls the textbee API (REST, the JavaScript SDK, or an AI agent through MCP).
- The API queues the message and wakes the phone with a Firebase Cloud Messaging push.
- The textbee Android app sends the text through Android's own SMS API, from the phone's SIM.
- The app reports each step back: sent, delivered or failed.
Incoming texts go the other way. The app uploads them, and textbee POSTs each one to your webhook.
Sending a text is one request:
curl -X POST https://api.textbee.dev/api/v1/gateway/send-sms \
-H "x-api-key: $TEXTBEE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"recipients": ["+12025550123"], "message": "Your code is 482913"}'
Or with the SDK:
import { Textbee } from '@textbee/sdk'
const textbee = new Textbee({ apiKey: process.env.TEXTBEE_API_KEY })
await textbee.sendSms({
recipients: ['+12025550123'],
message: 'Your table is ready',
})
When someone replies, your webhook gets a POST like this:
{
"webhookEvent": "MESSAGE_RECEIVED",
"sender": "+12025550123",
"message": "YES, please confirm my booking",
"receivedAt": "2026-10-20T09:14:03.000Z"
}
Each webhook endpoint has its own signing secret, and the SDK verifies the signature in one call.
What we learned running SMS on real phones
Battery savers are the main enemy. Samsung, Xiaomi, OnePlus and Pixel each stop background apps in their own way. A gateway that worked yesterday goes quiet after the screen turns off. The app now has a Device health screen that checks SMS permission, battery settings, power saving and the connection, with the fix for your phone's brand.
Accepted is not delivered. The API answers right away with a batch ID, before the phone has done anything. People expected a synchronous "delivered". So we made every state visible: the API and webhooks report sent, delivered and failed, and the app's Activity tab shows each step of a message with its time.
A phone has a pace. One phone sends about 10 to 15 messages a minute, which suits texts people expect: codes, reminders, "your order is ready". To send more, add more phones to the same account. It is not a tool for mass marketing.
Android keeps tightening SMS permissions. On recent Android versions, an app installed outside the Play Store needs "Allow restricted settings" before it can ask for SMS permission. We wrote a step-by-step guide because it trips up everyone the first time.
AI agents can text too
Our MCP server gives Claude, Cursor and other agents three tools: send_sms, get_messages and list_devices. Ask "text Sam that the order is ready" and the message goes out from your phone. Setup is at textbee.dev/mcp.
Open source or hosted
Everything is on GitHub: the Android app, the API and the dashboard. You can self-host the stack with Docker Compose (MongoDB, Redis and your own Firebase project).
Most people would rather not run a server to send a text, so there is also a hosted version with a free plan of 300 messages a month.
Try it in five minutes
- Install the Android app from textbee.dev/download.
- Sign in and turn on Gateway.
- Create an API key in the dashboard.
- Run the curl command above with your own number.
The docs cover bulk sends, scheduled messages, webhooks and self-hosting.
What would you use your phone's SMS for? Tell us in the comments. We read every one.
Top comments (1)
Waking the phone with FCM is the neat part, that is usually where people expect the battery cost to kill the idea. Reporting sent vs delivered vs failed separately is what makes it usable for anything real, most hobby gateways stop at "sent".