繁中 →
visitors so far

Claude Code Channels + Telegram

Run your AI from your phone — the full setup

← HomeAbout·Failure list·GitHub·Threads
?
What is Channels?

The 30-second version

Claude Code + a Telegram bot = your AI, run from your phone

Channels is a feature Anthropic shipped on March 20, 2026. It lets you command Claude Code through Telegram or Discord, so you do not have to sit at the computer. Open Telegram on your phone and you are working.

Picture this: you are out having coffee and you suddenly want to change a piece of code. You open Telegram, tell your bot to make the homepage heading 24px, and it is done.

30 seconds
to set up a Telegram bot
1 command
to install the Channels plugin
Anywhere
run Claude Code from your phone

The whole flow at a glance (read this first)

On the computer:
① Install Claude Code + Bun
② Install the Telegram plugin inside Claude Code
③ In Claude Code, run /telegram:configure and paste your token
④ Quit, then relaunch with claude --channels ... from the terminal

On Telegram, on your phone:
⑤ Create a Telegram bot (chat with @BotFather)
⑥ Copy the bot token (paste it in step ③)
⑦ Once the computer is running, message the bot to pair

Order matters: set everything up on the computer first, then go to Telegram and send a message.
If Telegram goes first, the bot stays silent, because the computer is not ready yet.

0
Before you start
Check you have all of these
  • Claude Code installed
  • An Anthropic API key or a Claude Max subscription
  • The Telegram app (phone or desktop, either works)
  • Bun (the Channels plugin needs it), the install command is below
  • A computer running Claude Code (Mac / Linux)
💡 Mac users can just use Terminal. Windows users should run Claude Code in WSL2 or PowerShell.
How do I open a terminal?

First time with Terminal

Mac: Press ⌘ + Space (Spotlight), type Terminal and press Enter.
Or go to Applications → Utilities → Terminal.

Windows: Press the Win key and search for PowerShell or CMD and press Enter.
Installing WSL2 makes it smoother.

No Claude Code yet?

Install Claude Code first

Open Terminal, copy and paste this line:

curl -fsSL https://claude.ai/install.sh | bash

When it finishes you will see ✔ Claude Code successfully installed!

Important: after installing you have to set PATH, copy and paste this line:
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc

Confirm the install worked:

claude --version

If it prints a version number (anything starting with2.x.x works), you are set.

Then run claude to start it. The first run asks you to log in to your Anthropic account.

No Bun yet?

Install Bun (the Channels plugin needs it)

Copy and paste this line:

curl -fsSL https://bun.sh/install | bash

After installing you have to set PATH, copy and paste:

echo 'export BUN_INSTALL="$HOME/.bun"' >> ~/.zshrc && echo 'export PATH="$BUN_INSTALL/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc

Confirm the install worked:

bun --version

A version number means you are good.

1
Create a Telegram bot
About 30 seconds

Find BotFather

Open Telegram and search for @BotFather(Telegram's official bot manager).

Open the chat and send this command:

/newbot

Name your bot

  1. BotFather asks for your bot's display name (anything you like, you can change it later)
    For example: My Claude Code
  2. Then it asks for your bot's username (it has to end in bot and be unique worldwide)
    For example: leo_claude_bot
  3. Once that works, BotFather hands you a bot token

Copy the bot token

A token looks like this:

123456789:ABCDefGhIjKlMnOpQrStUvWxYz
Careful: this token is your bot's password. Do not hand it to anyone, do not paste it anywhere public.
2
Install the Channels plugin
One command does it
STEP 1

Install the Telegram plugin

Open Claude Code (type claudein Terminal), then inside it type:

/plugin install telegram@claude-plugins-official

If it says the plugin cannot be found, run this first to add the official marketplace:

/plugin marketplace add anthropics/claude-plugins-official

Then install it again.

The installer asks which scope you want:

> Install for you (user scope)pick this one, press Enter
Install for all collaborators (project scope)
Install for you, in this repo only (local scope)
Back to plugin list

Take the first one, Install for you, so the plugin works in every project of yours.

Once it is installed, run:

/reload-plugins
STEP 2

Set the bot token

Inside Claude Code, type (without the token):

/telegram:configure
Careful: type /telegram:configure on its own, do not paste the token after it.

Claude asks you interactively whether to paste the token, paste it then.
If you type /telegram:configure YOUR_TOKENinstead, you get an “Unknown skill” error.
The token gets saved to ~/.claude/channels/telegram/.env, you only set it once.
STEP 3

Start Claude Code + Channels

Quit Claude Code first, then relaunch with this command:

claude --channels plugin:telegram@claude-plugins-official

When the Telegram plugin loads, you are connected.

3
First connection test
Confirm it all works
⚠️ Before you start: check Claude Code is running channels

The Telegram bot's replies come from Claude Code. If the terminal is closed, or the channels command is not running, the bot will not send back a pairing code (it looks broken, but really nobody is picking up).

Open the terminal and check this is running:
claude --channels plugin:telegram@claude-plugins-official
(the command from the previous step, keep that window open)
  1. Open Telegram and search for the bot you just created (by the username you set)
  2. Send the bot any message (“hi”, for example)
  3. The bot replies with a 6-digit pairing code
  4. Back in Claude Code, type this command (swap XXXXXX for the code you got):
/telegram:access pair XXXXXX

Once paired, lock it down so only you can drive it:

/telegram:access policy allowlist

Now go back to Telegram and send a test message:

Hi, tell me what the current working directory is

If the bot answers with your working directory, Channels is set up. 🎉

ADVANCED

Keep the connection alive with tmux

Closing the terminal drops the connection. Use tmux so Claude Code keeps running in the background:

# create a tmux session named claude tmux new -s claude # start channels inside it claude --channels plugin:telegram@claude-plugins-official # press Ctrl+B then D to leave (it keeps running) # to come back later: tmux attach -t claude
4
Real uses
The workflows I run every day
🔒

Want to see how I use Channels to post, watch communities, and answer comments?

These are the workflows I actually run

Includes: scheduled posting / community monitoring / smart replies / data reports

DM @kanisleo328 on IG and let's talk
?
FAQ

/telegram:configure says “Unknown skill”?

The Telegram plugin did not install properly. Fix it in this order:

1. Check whether the plugin is there:

/plugin list

2. If telegram is missing, add the marketplace:

/plugin marketplace add anthropics/claude-plugins-official

3. Install it again (pick “Install for you” and press Enter):

/plugin install telegram@claude-plugins-official

4. Reload after installing:

/reload-plugins

5. Try again (without the token):

/telegram:configure

Installed Claude Code but typing claude says “command not found”?

PATH is not set. Copy and paste this line, then press Enter:

echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc

If it still cannot find it, close Terminal, open a fresh one, and type claude.

Installed Bun but typing bun says “command not found”?

Same PATH problem as above. Copy and paste:

echo 'export BUN_INSTALL="$HOME/.bun"' >> ~/.zshrc && echo 'export PATH="$BUN_INSTALL/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc

The bot does not respond, now what?

Check in this order:
1. The computer is on and Claude Code is running
2. The bot token has no typos (run echo $TELEGRAM_BOT_TOKEN to confirm)
3. Restart with claude --channels plugin:telegram@claude-plugins-official
4. Confirm Telegram has a working network connection

Can several people use it at once?

Yes, but be careful about security. Channels supports an allowlist, so you can name which Telegram user IDs may drive your Claude Code. Only add people you trust, this is the same as letting them work your computer remotely.

Does it disconnect when the Mac shuts down?

Yes. Channels needs your computer to keep running Claude Code. Shutting down, sleeping, or closing the terminal all cut the connection. Use tmux or screen to keep the session alive, and set the Mac not to sleep on its own.

How is it different from OpenClaw?

Channels is an official Anthropic feature built into Claude Code, with no third-party service in between. OpenClaw is a community-built tool. The official one is usually more stable and more secure, and it keeps getting updates alongside Claude Code.

Is it safe? Where does the data go?

Your commands travel through the Telegram Bot API to Claude Code on your own computer, and Claude Code processes them through the Anthropic API. That means the code and file contents Claude reads go to Anthropic's servers as part of the conversation for inference, so it does not all stay local. The files on your disk are not copied away, but what Claude reads does pass through Anthropic. If security worries you, set an allowlist to limit who can drive it, and keep Claude away from genuinely confidential files.

Want more practical AI tips?

Follow Leo for firsthand experience, shared as it happens

Follow @kanisleo328

Found this useful? Cite it and pass it on