A lightweight, fully asynchronous Python application that creates multi-way bridges between Telegram chats, Discord channels, and WhatsApp groups/chats. Messages, media, reactions, and reply threads flow seamlessly across any number of configured bridges.
- Multi-way text bridging — messages sent on any platform in a bridge appear on all others.
- Reply threading — replies are matched and natively threaded on the receiving platforms.
- Reaction synchronization — bridge emoji reactions across platforms.
- Rich media support — photos, videos, audio, voice messages, stickers, and generic documents.
- Multiple bridges — configure different combinations of chats and platforms together seamlessly.
- Flexible Telegram auth — works as a bot (bot token) or a user account (phone number).
- Long message chunking — messages exceeding platform limits are automatically split.
- Simple to setup — configure
settings.yamland you're ready to go. - Docker support — includes a production-ready
Dockerfileanddocker-compose.yml
- Python 3.11+
- Git
- Docker and Docker Compose (optional)
- Make sure they are added to the PATH environment
- Discord (Bot): Create a Bot at discord.com/developers and copy the bot token and application ID. Enable all Privileged Gateway Intents (Message Content, Server Members, Presence).
- Telegram (Bot or User Account): Create an Application at core.telegram.org and copy the API ID and API Hash. Optionally, create a bot and obtain its token from @BotFather if you want a bot setup.
- WhatsApp (User Account): No prior setup required; you will scan a QR code in the terminal on the first run.
git clone https://github.com/MAymanKH/Bridger.git
cd BridgerCopy the example config and fill in your credentials:
cp example.settings.yaml settings.yaml# Platform credentials
# Only include the platforms you want to use.
platforms:
telegram:
api_id: 123456
api_hash: your_api_hash_here
# Choose ONE authentication method (both are optional — omit both for interactive login):
# bot_token: your_bot_token # Run as a Telegram bot
# phone: +12025551234 # Run as a user account
discord:
token: your_discord_bot_token
app_id: 123456789012345678
# Bridges
# Each bridge links two or more platform chats together.
bridges:
- name: my work bridge
platforms:
telegram: -123456 # Telegram chat ID (include the '-')
discord: 123456789 # Discord channel ID
whatsapp: 123456789@g.us # WhatsApp chat JID
- name: my homies bridge
platforms:
telegram: -654321
whatsapp: 987654321@g.usFinding chat IDs:
- Telegram: Forward a message to @userinfobot or use a Telegram API explorer. Group/channel IDs start with
-100. - Discord: Enable Developer Mode in settings, right-click a channel → Copy Channel ID.
- WhatsApp: Learn how to get chat JIDs here.
python -m venv venv
source venv/bin/activate # (On Windows: .\venv\Scripts\activate)
pip install -r requirements.txt
python main.pydocker-compose up -dsettings.yaml is mounted read-only into the container. Telegram session data and message queues are stored in named Docker volumes (telegram-sessions, message-data) so they persist across container restarts.
On the first run, if you configured a phone number (user account mode) for Telegram, you will be prompted for a verification code in the terminal. And for WhatsApp, you will be prompted to scan a QR code in the terminal. After a successful login the session is saved and subsequent starts require no interaction.
- The Discord bot requires the
Message Contentprivileged intent to read message text. - Make sure the Telegram bot has read access to the source chats (add it as an admin).
- This project is licensed under the GNU General Public License v3.0 - see the LICENSE file for details.