WP Manifestindependent plugin directory
manifest / email / telegram-mail-bridge

Telegram Mail Bridge

Copies WordPress emails to Telegram chats. Unlimited rules, bots and chats.

★ 1stars
2release downloads
v1.3.2latest · 4d ago

Install

Download telegram-mail-bridge-1.3.2.zip From the v1.3.2 release on GitHub, Oct 9, 2026

Upload it under Plugins → Add New Plugin → Upload Plugin, then activate.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/muzychenko-dev/telegram-mail-bridge/releases/download/v1.3.2/telegram-mail-bridge-1.3.2.zip
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

Copies emails your WordPress site sends through wp_mail() to Telegram chats. Unlimited rules, bots and chats, no account and no paid tier.

What it does

Every email that goes through wp_mail() - contact forms, bookings, WooCommerce orders, security alerts - is checked against your rules. When a recipient matches, the email is converted to Telegram formatting and posted to the rule's chats. The email itself is delivered as usual: the plugin reads the arguments and never changes them.

  • Rules: recipient addresses (office@example.com, *@example.com, any) → bot → one or more chats.
  • Several bots: tokens are activated once, checked with getMe and never shown again or sent to the browser.
  • Forum topics: -1001234567890:12 posts into topic 12 of a supergroup.
  • Templates: {email_subject} {email_message} {email_to} {site_name} {site_url} {date} {time} {attachments}.
  • Clean conversion: paragraphs, lists, links, tables as a | b; styles, comments and hidden preheaders removed; long emails split into balanced parts (5 messages at most by default).
  • Instant delivery: sent on shutdown after the response is handed to the visitor. No WP-Cron, no queue.
  • Tests: "Send test message" posts straight to the chats; "Send test email" goes through wp_mail() and checks the whole chain.
  • Log: last 40 deliveries with Telegram's error text and plain-language hints.
  • Updates: from GitHub releases, through the usual WordPress update screen.

Install

  1. Download telegram-mail-bridge-X.Y.Z.zip from Releases or the website.
  2. Plugins → Add New → Upload Plugin → Activate.
  3. Settings → Telegram Mail Bridge.

Moving from the old tg-mail-bridge folder (1.0-1.2)

Versions before 1.3.0 lived in tg-mail-bridge/. Install 1.3.0 next to it and activate: bots, rules and settings are copied, and the old copy is deactivated automatically so emails are not forwarded twice. Then delete the old plugin - its uninstaller removes only its own tmb_* options.

Set up

  1. Create a bot with @BotFather (/newbot), paste the token under Bots and click Activate.
  2. Get the chat ID from @MyChatInfoBot. For a private chat, write to your bot first; for a group, add the bot to it.
  3. Add a rule: recipient addresses, bot, chat IDs. Click Send test message, then save and click Send test email.

Token in wp-config.php

define( 'TGMB_BOT_TOKEN', '123456789:AA...' );

The bot appears in the list as locked and its token is not stored in the database, so it does not end up in backups or database exports. TMB_BOT_TOKEN from older versions still works.

For developers

// Change the text right before sending.
add_filter( 'tgmb_message_text', function ( $text, $rule, $mail_args ) {
    return $text;
}, 10, 3 );

// Skip a particular email.
add_filter( 'tgmb_should_forward', function ( $forward, $rule, $mail_args ) {
    return false === strpos( $mail_args['subject'], '[test]' );
}, 10, 3 );

// Most messages per email and chat (default 5).
add_filter( 'tgmb_max_parts', fn () => 3 );

// Turn off update checks against GitHub.
add_filter( 'tgmb_enable_updates', '__return_false' );

// After delivery or failure.
add_action( 'tgmb_sent', function ( $message, $chat_id, $rule, $mail_args ) {}, 10, 4 );
add_action( 'tgmb_failed', function ( $error, $chat_id, $rule, $mail_args ) {}, 10, 4 );

WP-CLI

wp tgmb status              # bots (masked) and rules
wp tgmb test 1              # test message to the chats of rule 1
wp tgmb test 1 --mail       # real email through wp_mail() to rule 1
wp tgmb log                 # delivery log
wp tgmb log --clear

Limits

  • Only wp_mail() is seen. Plugins that call a mail service API directly (SendGrid or Mailgun SDKs) bypass it. SMTP plugins are fine.
  • Attachments are not sent, only their names through {attachments}.
  • Email content goes to api.telegram.org and stays in the chat. The rule any also forwards password reset links - avoid it on client sites.
  • Masking keeps tokens out of sight, not out of reach: anyone with administrator access can read the database. Use a separate bot per client site.
  • Security plugins may flag requests to api.telegram.org. Add the host to trusted ones.

Data

Option Content
tgmb_settings bots (tokens), rules, switches
tgmb_log last 40 deliveries: time, subject, chat, result
tgmb_const_bot_username public name of the wp-config.php bot
tgmb_imported_legacy when settings were copied from tg-mail-bridge

Nothing is autoloaded. Deleting the plugin removes every tgmb_* option and the update checker state.

Releasing (maintainer notes)

  1. Bump the version in telegram-mail-bridge.php (header and TGMB_VERSION), in readme.txt (Stable tag and Changelog) and in this README.
  2. wp i18n make-pot . languages/telegram-mail-bridge.pot --domain=telegram-mail-bridge --exclude=languages,lib,tools and python3 tools/make-uk.py.
  3. git archive --prefix=telegram-mail-bridge/ -o telegram-mail-bridge-X.Y.Z.zip HEAD
  4. Create a GitHub release with tag vX.Y.Z and attach that zip. Sites update from the attached zip only; a release without it is ignored.

Author

Ihor Muzychenko - muzychenko.dev

Not affiliated with Telegram.

Releases

2 releases. Each count is every asset in that release; expand a row for the breakdown.

Tag
Published
Assets
Downloads
v1.3.2 latest
Oct 9, 2026 4d ago
telegram-mail-bridge-1.3.2.zip
1
Oct 3, 2026 10d ago
telegram-mail-bridge-1.3.1.zip
1