Tutorial

OpenClaw Telegram Setup: Full Tutorial (2026)

Connect your OpenClaw agent to Telegram and message your AI from anywhere in the world โ€” on your phone, tablet, or desktop. Full step-by-step guide including multi-bot setup.

๐Ÿฆž claw.mobile EditorialยทMarch 22, 2026ยท
10 min read

Why Telegram Is the Best Channel for OpenClaw

Telegram isn't just a messaging app โ€” it has a robust, free bot API that makes it the perfect interface for your AI agent.

๐ŸŒ

Works everywhere

iOS, Android, desktop, web. Message your agent from any device.

โœจ

Rich formatting

Markdown support, inline buttons, file sending, voice messages.

๐Ÿ†“

Free bot API

No rate limits for normal usage, no API costs for the channel itself.

๐Ÿ””

Fast notifications

Instant push notifications when your agent completes tasks.

๐Ÿ‘ฅ

Groups & channels

Add your agent to a group to collaborate with a team.

๐Ÿ“ฒ

Always accessible

Telegram is already on every device you own. No new apps needed.

Step 1: Create Your Telegram Bot via BotFather

Every Telegram bot needs to be registered with @BotFather, Telegram's official bot creation service. This takes about 2 minutes.

1

Open Telegram and find @BotFather

Search for "@BotFather" in Telegram. It's the official verified account (blue checkmark). Open a chat with it.

2

Start the bot creation process

Send the command /newbot to BotFather. It will ask for a name and username.

3

Choose a name and username

Name: displayed to users (e.g., "My AI Agent"). Username: must end in "bot" (e.g., @myagent_bot). Usernames are permanent.

4

Copy your bot token

BotFather will give you a token like 1234567890:AAFqV1WAoDxZP9dAt8wMp4BWaWi5s-MUrIs. Save this โ€” you'll need it next.

Keep Your Token Secret

Your bot token is like a password. Anyone with it can control your bot. Never post it publicly, never commit it to Git.

Optional: Customize Your Bot

BotFather commands
# Set a description
/setdescription โ†’ select your bot โ†’ enter description

# Set a profile picture
/setuserpic โ†’ select your bot โ†’ send a photo

# Set commands (shows up as "/" menu in Telegram)
/setcommands โ†’ select your bot โ†’ paste:
help - Show available commands
status - Check agent status
cancel - Cancel current task

Step 2: Connect Your Bot to OpenClaw

Method A: Interactive Setup (Recommended)

Terminal
openclaw channel add telegram

OpenClaw will prompt you for your bot token. Paste it and press Enter. That's it.

Method B: Direct Config Edit

~/.openclaw/config/openclaw.json
{
  "plugins": {
    "telegram": {
      "enabled": true,
      "token": "1234567890:AAFqV1WAoDxZP9dAt8wMp4BWaWi5s-MUrIs",
      "allowedUserIds": [],
      "adminUserIds": [],
      "reactions": "minimal",
      "parseMode": "Markdown"
    }
  }
}

allowedUserIds vs adminUserIds

Leave allowedUserIds empty to allow anyone. Fill it with your Telegram user ID to restrict to just you. adminUserIds get extra privileges like running shell commands.

Finding Your Telegram User ID

Find your Telegram User ID
# Method 1: Message @userinfobot on Telegram
# It replies with your user ID instantly

# Method 2: Message @RawDataBot
# Look for "id" field in the "from" object

Restart the Gateway

Terminal
openclaw gateway restart

Step 3: Test the Connection

Open Telegram, find your bot by username, and start a chat. Send: /start

You should receive a welcome message from your agent. Then try a real message:

Test messages
"What's today's date?"
"What's the weather in London?"
"Summarize this URL: https://example.com"
Terminal โ€” verify connection
# Watch live logs
openclaw logs --follow --channel telegram

# Check overall status
openclaw status

Step 4: Secure Your Bot

A Telegram bot connected to your AI agent is a powerful interface. Lock it down properly.

Security config
{
  "plugins": {
    "telegram": {
      "token": "YOUR_TOKEN",
      "allowedUserIds": [YOUR_TELEGRAM_ID],
      "adminUserIds": [YOUR_TELEGRAM_ID],
      "rejectUnauthorized": true,
      "silentReject": true
    }
  }
}

silentReject: true means unauthorized users don't even get a "you're not allowed" message โ€” the bot simply ignores them. This prevents bot enumeration.

Advanced: Multiple Bots & Notification Setup

Running Two Bots (Personal + Notifications)

A common pattern: one bot for conversation, one for push notifications.

Dual-bot config
{
  "plugins": {
    "telegram": {
      "enabled": true,
      "token": "MAIN_BOT_TOKEN",
      "allowedUserIds": [YOUR_ID]
    },
    "telegram-notify": {
      "enabled": true,
      "token": "NOTIFICATION_BOT_TOKEN",
      "defaultChatId": YOUR_CHAT_ID,
      "notificationsOnly": true
    }
  }
}

Scheduled Telegram Notifications

Cron job for daily report
{
  "schedule": "0 9 * * *",
  "message": "Send me a daily briefing via Telegram: check my calendar for today's events, summarize the top 3 tech news stories, and remind me of any tasks from MEMORY.md due today.",
  "channel": "telegram"
}

Troubleshooting

Bot Not Responding

  1. 1Check gateway is running: openclaw gateway status
  2. 2Verify the token is correct in config
  3. 3Check logs: openclaw logs --follow
  4. 4Make sure your user ID is in allowedUserIds (or it's empty)

"Conflict: terminated by other getUpdates request"

  1. 1This means OpenClaw is running twice
  2. 2Kill all processes: openclaw gateway stop && pkill -f openclaw
  3. 3Restart fresh: openclaw gateway start

Now Set Up Your First Automation

Telegram is connected. Next step: set up automations that run while you sleep.

5 Automations to Set Up Today
We use cookies for analytics. Learn more
Run your own AI agent for $6/month โ†’