OpenClaw Telegram Bot — How to Connect OpenClaw to Telegram
The killer feature of OpenClaw is that it's not trapped in a browser tab. It lives in your messaging app — available on your phone, your tablet, your desktop, anywhere Telegram runs. You message it like a friend. It messages you back proactively.
But connecting OpenClaw to Telegram isn't exactly plug-and-play. Here's how to do it both ways: the manual setup, and the 60-second shortcut.
The Hard Way: DIY Telegram Integration
Prerequisites
- A running OpenClaw instance (see our hosting guide)
- A domain name pointing to your server
- A valid SSL certificate (Let's Encrypt works)
- Nginx or similar reverse proxy configured
Step 1: Create Your Bot
- Message @BotFather on Telegram
- Send
/newbot - Name your bot (e.g., "My AI Assistant")
- Pick a username ending in
bot(e.g.,my_ai_assistant_bot) - Save the token BotFather gives you — you'll need it
Step 2: Find Your User ID
Message @userinfobot on Telegram. It'll reply with your numeric user ID. You need this to restrict who can talk to your bot.
Step 3: Configure OpenClaw
# In your OpenClaw config.yaml:
channels:
telegram:
enabled: true
token: "7123456789:AAH..." # from BotFather
allowedUsers:
- 123456789 # your Telegram user ID
webhook:
url: "https://yourdomain.com/telegram/webhook"
port: 8443
Step 4: Set Up Nginx Proxy
server {
listen 443 ssl;
server_name yourdomain.com;
ssl_certificate /etc/letsencrypt/live/yourdomain.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/yourdomain.com/privkey.pem;
location /telegram/webhook {
proxy_pass http://127.0.0.1:3000;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
}
}
Step 5: Register the Webhook
curl -X POST "https://api.telegram.org/bot<YOUR_TOKEN>/setWebhook" \
-d "url=https://yourdomain.com/telegram/webhook"
Step 6: Test It
Message your bot on Telegram. If everything is configured correctly — DNS, SSL, Nginx, OpenClaw config, webhook registration — you'll get a reply.
If you don't: welcome to webhook debugging hell. Check DNS propagation, SSL cert validity, Nginx error logs, OpenClaw logs, and the Telegram getWebhookInfo API.
Time estimate: 1-3 hours on top of the base OpenClaw installation. Longer if you hit SSL or DNS issues.
The Easy Way: ClawHatch (60 Seconds)
ClawHatch handles all of the above — server, Node.js, SSL, Nginx, webhook, BotFather configuration — automatically.
- Open Telegram → @ClawHatchBot
- Send
/start - Paste your API key
- Done. Bot is live.
No domain. No SSL. No Nginx. No webhook debugging.
What Can You Do with the Telegram Bot?
Once connected, your OpenClaw Telegram bot can:
- Send and receive text messages — just like chatting with a friend
- Read images — send a photo of a receipt, prescription, or document
- Send voice messages — the bot transcribes and responds
- Set reminders — "Remind me to call the dentist at 3pm"
- Message you proactively — morning briefings, price alerts, scheduled reports
- Execute workflows — code reviews, email drafts, smart home control
- Spawn sub-agents — specialist AI teams that research, code, and write for you
Get OpenClaw in Telegram. Now.
7-day free trial. No server required. 60 seconds to first message.
Start free trial