Copilot Chat Remote (Telegram)
Keep talking to GitHub Copilot Chat in any of your open VS Code windows from your phone, through a private Telegram bot that only you can use.
You leave several projects open, each with its own Copilot chats. Away from the desk you can pick a project, pick a chat (or start a new one), send a message, watch the answer as it is written, and allow or deny tool confirmations (terminal commands, file edits…) with a button.
Preview. This extension drives Copilot Chat through internal VS Code commands and reads Copilot's local session files. It is tested with VS Code 1.143. A VS Code or Copilot update can break it until a new version is released.
How it works
- Every VS Code window runs a small HTTP endpoint bound to
127.0.0.1, protected by a random 256-bit token that changes on every start.
- Exactly one window runs the Telegram bot (it holds a local lock). If that window closes, another one takes over within ~15 seconds.
- The bot uses Telegram long polling: no inbound ports, no server of your own.
- Chat history is read from Copilot's local files in a separate process with a memory cap, so even huge chats can never take down VS Code.
Setup
- In Telegram, talk to @BotFather, send
/newbot and copy the token.
- In VS Code click Remote in the status bar (or run Copilot Chat Remote: Configure Telegram bot) and paste the token. It is stored in the OS keychain (VS Code SecretStorage), never in
settings.json.
- Choose Pair phone. Send the displayed
/start <code> to your bot (or open the t.me link on your phone). The code is single-use, expires in 10 minutes and is revoked after 5 wrong attempts.
Bot commands
| Command |
|
/projects |
Pick a VS Code window |
/chats |
Chats of that window, or start a new one |
/new [agent\|ask] |
Next message starts a new chat |
/show [n] |
Last n exchanges of the current chat |
/stop |
Cancel the running response |
| any text |
Sent to the selected chat |
The bot answers in Spanish or English depending on your Telegram language; Spanish commands (/proyectos, /nuevo, /ver, /parar) also work.
Notices while you are away
When a chat in any exposed window finishes, fails or waits for a confirmation and you could not have seen it in VS Code, the bot sends it to you: the answer, or the confirmation with Allow / Deny buttons. Continue here selects that chat so your next message goes to it.
You count as away when, for copilotRemote.notify.awayMinutes minutes (default 5):
- the computer has had no keyboard or mouse input, or is locked (
copilotRemote.notify.whenIdle, macOS only), or
- no VS Code window has had focus (
copilotRemote.notify.whenUnfocused).
Events that happened before you left, or after you came back, are not sent. Responses you are already following from Telegram are not repeated.
Settings
| Setting |
|
copilotRemote.telegram.enabled |
Run the bot (default true). |
copilotRemote.excludeWindows |
Window names (substring, case-insensitive) that are never exposed. An excluded window does not even open its local endpoint. |
copilotRemote.exposeWindow |
Set to false in a workspace's settings to hide that project. |
copilotRemote.notify.whenIdle |
Notify when the computer is idle or locked (default true, macOS only). |
copilotRemote.notify.whenUnfocused |
Notify when no VS Code window has focus (default true). |
copilotRemote.notify.awayMinutes |
Minutes away before notifying (default 5). |
Security and privacy
- Your prompts and Copilot's answers travel through Telegram's servers. Exclude any project whose code or data must not leave your machine (company code, credentials, personal data).
- Only paired private chats are served; messages from anyone else are ignored. Messages queued while no bot was running are discarded, so stale prompts never execute.
- Anyone with your phone and Telegram session can drive Copilot on your machine, including approving terminal commands. Use Forget paired phones if you lose the device.
Limitations
- New chats (Copilot CLI sessions, the default in recent VS Code) stream live. Older local chats only show the reply after VS Code saves them (use
/show).
- Multiple-choice questions asked by the agent must be answered in VS Code.
- Your computer must be awake with VS Code open.
En español
Continúa desde el móvil tus chats de GitHub Copilot en cualquier ventana abierta de VS Code mediante un bot privado de Telegram. Configúralo desde Remote en la barra de estado: pega el token de @BotFather (se guarda en el llavero del sistema) y empareja el móvil con el código /start. Si te alejas de VS Code (Mac inactivo o bloqueado, o ninguna ventana de VS Code con el foco durante los minutos configurados), el bot te avisa cuando un chat termina, falla o espera confirmación. Con copilotRemote.excludeWindows puedes impedir que un proyecto pase por Telegram. Los mensajes y respuestas viajan por los servidores de Telegram: no expongas proyectos con código o datos confidenciales.
Not affiliated with, endorsed or sponsored by GitHub, Microsoft or Telegram. "GitHub Copilot" is a trademark of GitHub, Inc.