Connect Telegram to OpenClaw
Run your OpenClaw AI assistant as a Telegram bot. This guide walks you through getting your user ID, creating a bot, and launching your instance. The whole process takes about 2 minutes.
How it works
OpenClaw connects to Telegram using the Bot API. You create a bot with @BotFather, get a token, and paste it into the setup wizard. Your instance then runs the bot so only people you approve (your allowlist) can message it.
You'll need:
- Your Telegram user ID — so the bot knows you're allowed to message it (and so you can add more users later).
- Bot token — from BotFather, so OpenClaw can run your bot.
Step 1: Get your Telegram user ID
OpenClaw uses an allowlist: only Telegram users you add can message your bot. To add yourself (and others), you need numeric user IDs. The easiest way is our helper bot:
- Open Telegram and go to @openclaw_setup_helper_bot.
- Send any message (e.g.
/startor "Hi"). - The bot replies instantly with your numeric user ID (e.g.
123456789). - Copy that number — you'll paste it into the setup wizard as your first allowlist user.
Tip: To allow more people later, they can message @openclaw_setup_helper_bot to get their ID, then you add their ID in the dashboard allowlist.
Step 2: Create your Telegram bot
- In Telegram, open @BotFather.
- Send
/newbotand follow the prompts: choose a name and username for your bot (e.g. "My OpenClaw Assistant" andmy_openclaw_bot). - BotFather replies with a token that looks like
1234567890:ABCdefGHIjklMNOpqrsTUVwxyz. - Copy the token and keep it secret — treat it like a password.
Step 3: Enter everything in OpenClaw Setup
- Go to the OpenClaw Setup dashboard.
- Start the setup wizard and choose Telegram (or Telegram + Slack).
- Paste your Telegram user ID (from Step 1) in the allowlist step.
- Paste your bot token (from Step 2).
- Configure your LLM provider and click Launch.
Your OpenClaw assistant will connect to Telegram and start responding. Only users on your allowlist can message the bot; everyone else is ignored.
Step 4: Manage the allowlist (optional)
After launch, you can add or remove allowed users from the dashboard:
- Open your instance and go to the Telegram section.
- Add more Telegram user IDs (each person can get theirs from @openclaw_setup_helper_bot).
- You can also configure group access if you want the bot in specific Telegram groups.
Troubleshooting
- Bot doesn't respond to me
- Check that your Telegram user ID is in the allowlist. Get it from @openclaw_setup_helper_bot and add it in the dashboard.
- Token validation fails
- Make sure you copied the full token from BotFather (no extra spaces). The token usually has numbers, a colon, and a long alphanumeric string.
- I need another user's ID
- They can message @openclaw_setup_helper_bot — it replies with their ID. Then add that ID to your instance's Telegram allowlist.
Get your Telegram user ID
Message our helper bot on Telegram — it replies instantly with your numeric user ID. Use it for the setup wizard and when adding people to your allowlist.
Open @openclaw_setup_helper_botReady to launch?
Once you have your user ID and bot token, go to the dashboard to complete setup and launch your Telegram assistant.