Keep the phone online
Stop Android from pausing the textbee app: the Device health screen, battery settings for each phone maker, physical setup and the device heartbeat.
Updated
Android pauses apps in the background to save battery, and many phone makers add stricter rules on top. When Android pauses textbee, messages wait in both directions: sends stay pending, and incoming SMS upload late. The fix is a few settings on the phone, which the app's Device health screen checks for you.
What a paused app does to your messages
| Direction | What happens while the app is paused |
|---|---|
| Sending | The push with the message waits. The message stays pending until the phone wakes, sometimes for minutes or hours. |
| Receiving | The SMS arrives on the phone, but the upload waits. Your webhook and message history get it late. |
| Heartbeat | The device stops checking in. lastHeartbeat gets old, and the dashboard shows the device as offline. |
Nothing is lost in a short pause. The app catches up when it runs again. A phone that is paused for many hours makes textbee slow and hard to trust.
Check the Device health screen
Open the textbee app and go to Settings > Device health. The screen shows "What can slow down or stop messages on this phone, in either direction, and what to change." Each row has a status and, where it helps, a button that fixes it.
| Row | Good value | If it is not good |
|---|---|---|
| SMS permissions | Granted | Tap Grant. The row lists what is missing: Send SMS, Receive SMS or Phone state. "The gateway cannot work without them." |
| Notifications | Allowed | Tap Allow. "Not allowed. textbee cannot show that it is running, and Android stops it sooner in the background." Only Android 13 and later ask for this. |
| Battery usage | Unrestricted | Tap Open settings and set textbee to Unrestricted. "Android may pause textbee in the background and hold messages for minutes or hours." |
| Sticky notification | "On. A permanent notification tells Android to keep textbee running." | Tap Turn on. The sticky notification cannot start until the Receive SMS permission is granted. |
| Power saving right now | Off | This is the current state, not a setting. "Messages may wait until the phone wakes." Turn off battery saver and plug the phone in. |
| Send delay | A gap of a few seconds | Information only. The row shows how many messages a minute the phone sends and how long 500 recipients take. |
| Heartbeat | A time under 45 minutes ago | Tap Send heartbeat. See The heartbeat below. |
| Tips for your phone brand | Shown on some brands | Follow the steps in the row, or the steps for your brand below. Tap Open app settings to start. |
The Device health entry in Settings shows All checks pass when nothing needs a change.
Settings for each phone maker
Set battery usage to Unrestricted on every phone. Many brands also have their own app manager that stops apps. The app shows the steps for your brand on the Device health screen. They are the same steps as below.
Stock Android and Pixel
The app shows no brand tips for these phones. The Battery usage row is enough.
- On the Device health screen, tap Open settings on the Battery usage row.
- Set textbee to Unrestricted. On Android 12 and later, this is also at Settings > Apps > textbee > App battery usage > Unrestricted.
- Turn on the Sticky Notification in the textbee settings.
Samsung
Settings > Battery and device care > Battery > Background usage limits: add textbee to Never sleeping apps, and make sure Put unused apps to sleep does not include it.
Xiaomi (also Redmi and POCO)
Settings > Apps > Manage apps > textbee: turn on Autostart, and under Battery saver choose No restrictions. Then in Security > Boost speed > Lock apps, lock textbee.
Huawei (also Honor)
Settings > Battery > App launch > textbee: turn off automatic management and allow Auto-launch, Secondary launch and Run in background.
OPPO (also Realme)
Settings > Battery > App battery management > textbee: allow background activity. Also enable Auto-launch under App management.
vivo (also iQOO)
Settings > Battery > Background power consumption management: allow textbee. Then in iManager > App manager > Autostart, enable textbee.
OnePlus
Settings > Battery > Battery optimization > textbee: Don't optimize. Also turn off Advanced optimization and Sleep standby optimization.
Tecno and Infinix (also itel)
Settings > Battery > App power management: allow textbee. In Phone Master > Auto-start management, enable textbee.
Menu names change between Android versions and phone models. If a menu is missing, search the phone's settings for the last item in the path, for example "Autostart".
Physical setup
- Keep the phone plugged in. A gateway phone runs all day. A charger also keeps most phones out of power saving.
- Use Wi-Fi for data. Wi-Fi keeps the connection to textbee stable. The SIM still needs mobile service to send and receive SMS.
- Turn off battery saver. Battery saver and idle mode hold messages until the phone wakes.
- The screen can be off. textbee works with the screen off and the phone locked, once the settings above are right.
- Do not force-stop the app. Do not swipe textbee away with a cleaner app or a "clear all" button that kills apps.
- Keep the SIM active. Check that the plan has SMS credit and that the SIM does not expire.
The heartbeat
The app sends a heartbeat to textbee at a fixed interval. The device field heartbeatIntervalMinutes sets the interval. It is 30 minutes by default. lastHeartbeat is the time of the last heartbeat that arrived.
This call shows lastHeartbeat for each phone:
curl https://api.textbee.dev/api/v1/gateway/devices \
-H "x-api-key: YOUR_API_KEY"The Device health screen rates the last heartbeat:
| Age of the last heartbeat | What the app shows |
|---|---|
| Under 45 minutes | The time, in green |
| 45 minutes to 3 hours | "Expected every 30 minutes." |
| Over 3 hours | "Android or the phone maker is probably stopping the app in the background." |
| Never | "Never. Send one to check the connection." |
| Dated in the future | The phone clock changed. The next heartbeat clears this. |
Tap Send heartbeat to send one now. If the time updates, the phone can reach textbee. If it fails, check the internet connection. If the heartbeat works but goes stale again, go back to the battery settings for your brand.
The device record also has batteryInfo, networkInfo and powerInfo from the last heartbeat. powerInfo shows the Android power state. It explains a device that is online but slow to send. See Devices for every field.
Use a dedicated phone
For a gateway that runs all day, use a phone that does nothing else:
- Nobody turns on battery saver or closes apps on it.
- Your own calls and messages do not compete with the gateway.
- You can leave it plugged in and on Wi-Fi in one place.
- A problem with the gateway does not affect your personal phone.
An older Android phone with Android 7.0 or later and a SIM with an SMS plan is enough. For more volume or redundancy, add a second phone. See Devices.
Frequently asked questions
Does the sticky notification drain the battery?
The notification itself uses very little power. It tells Android that textbee is running, so Android stops it less often.
Will I lose messages when the phone is offline?
Sends wait and go out when the phone is back. Incoming SMS stay on the phone and upload later. Webhooks for those messages arrive late.
The Device health screen shows no tips for my brand. What do I do?
Set battery usage to Unrestricted and turn on the sticky notification. Then look in the phone settings for an app manager with options like "Autostart" or "Background activity", and allow textbee there.
Do I need to open the app after a restart?
Open it once after a restart and check that the sticky notification is back. Then tap Send heartbeat on the Device health screen.