Why Telegram
OpenClaw runs best when you can reach it from your phone. The dashboard is fine for setup, but nobody wants to SSH into a VPS just to ask the agent to summarize yesterday's messages. Telegram is the lowest-friction channel: free, no port forwarding, and the bot API does the heavy lifting for you.
Create the bot
You do this once, inside the Telegram app, not on your server.
- Open Telegram and search for @BotFather — it's the official bot that makes other bots. Make sure it has the verified checkmark.
- Send it
/newbotand answer the two questions: a display name (anything) and a username (must end inbot, likemyclawbot). - BotFather replies with an API token that looks like
123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11. Save it somewhere you won't lose it.
Treat that token like a password. Anyone who has it can read and send messages as your bot. I keep mine in a password manager, not in a screenshot folder.
Point OpenClaw at it
Back on your server, add Telegram as a channel. The exact command differs slightly between releases, so if the one below errors out, check the current channel docs rather than fighting it.
openclaw config set channels.telegram.botToken "YOUR_BOT_TOKEN"
openclaw config set channels.telegram.enabled true
Restart the agent after changing the config. If you're running it under systemd from my VPS guide, that's:
sudo systemctl restart openclaw
The chat ID step
This is where most people stall. The bot needs a chat ID to know where to send messages, and Telegram doesn't hand it to you in the app. The quick way is to message the bot once and then ask the API who sent it. Depending on your setup, a getUpdates call or a helper command in the agent will print the sender's ID.
For a group, add the bot to the group first, then send any message — the group chat ID shows up in the update payload. If the bot never replies, nine times out of ten it's because the chat ID is missing or wrong, not because the token is bad.
Test and troubleshoot
Send your bot a short message: "What's the current time?" If it comes back with a sane answer, you're done. If it's silent, work through this list in order:
- Is the
enabledflag actuallytrue? It's easy to set the token and forget the toggle. - Did you restart after changing config? OpenClaw reads config at startup.
- Is the chat ID correct? Wrong ID = the bot is talking into the void.
- Does the token have a stray space from copy-paste? Trim it.
One last thing worth doing: set a strong auth boundary before you expose the bot to any group with strangers in it. A public bot that can run shell commands is an invitation you don't want to send.