[GH-ISSUE #4871] [Bug]: Telegram bot proxy settings removed from panel UI but still honored by backend #3402

Closed
opened 2026-10-31 20:32:11 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @yukh975 on GitHub (Jun 3, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/4871

Describe the bug

In earlier versions of the panel settings there were fields to configure a proxy for the Telegram bot. In the current version these fields are gone from the UI, so there's no way to set or change the Telegram proxy through the panel anymore.
However, the old settings that were previously added to x-ui.db are still read and used by the backend — the Telegram bot continues to work through the proxy configured under the earlier version. So the functionality still exists on the backend, but it's no longer exposed in the panel.

Result

  • New installs / users who never set this value have no way to configure a Telegram bot proxy from the UI.

  • Existing users who had it configured keep working, but can't view or change the setting from the panel — only by editing x-ui.db directly.

How to reproduce the problem

  1. On an earlier version of the panel that still had the Telegram proxy fields, configure a proxy for the Telegram bot (this writes the value into x-ui.db).
  2. Upgrade to the current version.
  3. Open the panel settings and look for the Telegram bot proxy fields — they are no longer present in the UI.
  4. Observe that the Telegram bot still connects through the previously configured proxy, i.e. the backend is still reading and using the old value from x-ui.db even though it can no longer be viewed or changed from the panel.

For a fresh install on the current version, there is no way to set the Telegram bot proxy from the UI at all.

Expected behavior

Either restore the Telegram bot proxy fields in the panel settings, or document that the setting is intentionally backend-only and how to set it.

Actual behavior

No response

Relevant logs


Screenshots

No response

3x-ui version

3.2.6

Xray-core version

26.6.1

How did you install 3x-ui?

install.sh script

Operating system

Debian 13

Which parts of the panel are affected?

Frontend (UI / panel pages)

Browser (only if it is a UI bug)

No response

Is the panel behind a reverse proxy or CDN?

Yes — Caddy

Before submitting

  • I searched existing issues and this bug has not been reported.
  • I am running the latest released version of 3x-ui (or have verified the bug still exists on it).
  • This bug report is written in English.
  • I have redacted any sensitive data (tokens, real domains, client UUIDs).
Originally created by @yukh975 on GitHub (Jun 3, 2026). Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/4871 ### Describe the bug In earlier versions of the panel settings there were fields to configure a proxy for the Telegram bot. In the current version these fields are gone from the UI, so there's no way to set or change the Telegram proxy through the panel anymore. However, the old settings that were previously added to x-ui.db are still read and used by the backend — the Telegram bot continues to work through the proxy configured under the earlier version. So the functionality still exists on the backend, but it's no longer exposed in the panel. Result - New installs / users who never set this value have no way to configure a Telegram bot proxy from the UI. - Existing users who had it configured keep working, but can't view or change the setting from the panel — only by editing x-ui.db directly. ### How to reproduce the problem 1. On an earlier version of the panel that still had the Telegram proxy fields, configure a proxy for the Telegram bot (this writes the value into x-ui.db). 2. Upgrade to the current version. 3. Open the panel settings and look for the Telegram bot proxy fields — they are no longer present in the UI. 4. Observe that the Telegram bot still connects through the previously configured proxy, i.e. the backend is still reading and using the old value from x-ui.db even though it can no longer be viewed or changed from the panel. For a fresh install on the current version, there is no way to set the Telegram bot proxy from the UI at all. ### Expected behavior Either restore the Telegram bot proxy fields in the panel settings, or document that the setting is intentionally backend-only and how to set it. ### Actual behavior _No response_ ### Relevant logs ```shell ``` ### Screenshots _No response_ ### 3x-ui version 3.2.6 ### Xray-core version 26.6.1 ### How did you install 3x-ui? install.sh script ### Operating system Debian 13 ### Which parts of the panel are affected? Frontend (UI / panel pages) ### Browser (only if it is a UI bug) _No response_ ### Is the panel behind a reverse proxy or CDN? Yes — Caddy ### Before submitting - [x] I searched [existing issues](../issues?q=is%3Aissue) and this bug has not been reported. - [x] I am running the latest released version of 3x-ui (or have verified the bug still exists on it). - [x] This bug report is written in English. - [x] I have redacted any sensitive data (tokens, real domains, client UUIDs).
bsakaguchi 2026-10-31 20:32:11 +07:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@github-actions[bot] commented on GitHub (Jun 3, 2026):

Thank you for the detailed report — your observations are correct, and here is what is happening in the code.

What changed

The per-bot tgBotProxy setting was intentionally replaced with a panel-wide proxy in ~v3.2.x (see #4706). The dedicated Telegram proxy UI fields were removed from the Telegram settings tab and a single "Panel Network Proxy" field was added to the General settings tab instead.

Where to set it now

Settings → General → Panel Network Proxy (panelProxy)

The field description reads:

Routes the panel's own outbound requests (geo updates, Xray/panel version checks, Telegram) through this proxy to bypass server-side filtering of GitHub/Telegram. Accepts socks5:// or http(s)://, e.g. a local Xray SOCKS inbound. Leave empty for a direct connection.

So configuring a proxy there will cover the Telegram bot.

Why existing setups keep working

The backend (web/service/tgbot.go) falls back gracefully:

  1. It reads tgBotProxy from the DB first.
  2. If that is empty, it falls back to panelProxy.

Old installations that had tgBotProxy set before the migration still have that value in x-ui.db, so the bot continues working through it. The value just cannot be viewed or cleared from the current UI — which is the legitimate UX gap you identified.

Workaround for existing users who want to migrate

If you previously had tgBotProxy set and want to consolidate to the new field:

  1. Set the proxy URL in Settings → General → Panel Network Proxy.
  2. Clear the old tgBotProxy value from the DB directly:
    UPDATE settings SET value = '' WHERE key = 'tgBotProxy';
    
    (Run against /etc/x-ui/x-ui.db via sqlite3, then restart x-ui.)
    After that the bot will use panelProxy.

Summary

  • New installs: configure the proxy via Settings → General → Panel Network Proxy — that setting explicitly covers Telegram.
  • Existing installs: old tgBotProxy values still work; optionally migrate using the steps above.

The remaining gap is that the Telegram settings tab gives no indication that its proxy lives in General settings, which can confuse users. That would be worth a small UI hint or tooltip on the Telegram tab.

<!-- gh-comment-id:4615840915 --> @github-actions[bot] commented on GitHub (Jun 3, 2026): Thank you for the detailed report — your observations are correct, and here is what is happening in the code. ## What changed The per-bot `tgBotProxy` setting was intentionally replaced with a **panel-wide proxy** in ~v3.2.x (see #4706). The dedicated Telegram proxy UI fields were removed from the Telegram settings tab and a single "Panel Network Proxy" field was added to the **General** settings tab instead. ## Where to set it now **Settings → General → Panel Network Proxy** (`panelProxy`) The field description reads: > Routes the panel's own outbound requests (geo updates, Xray/panel version checks, **Telegram**) through this proxy to bypass server-side filtering of GitHub/Telegram. Accepts `socks5://` or `http(s)://`, e.g. a local Xray SOCKS inbound. Leave empty for a direct connection. So configuring a proxy there will cover the Telegram bot. ## Why existing setups keep working The backend (`web/service/tgbot.go`) falls back gracefully: 1. It reads `tgBotProxy` from the DB first. 2. If that is empty, it falls back to `panelProxy`. Old installations that had `tgBotProxy` set before the migration still have that value in `x-ui.db`, so the bot continues working through it. The value just cannot be viewed or cleared from the current UI — which is the legitimate UX gap you identified. ## Workaround for existing users who want to migrate If you previously had `tgBotProxy` set and want to consolidate to the new field: 1. Set the proxy URL in **Settings → General → Panel Network Proxy**. 2. Clear the old `tgBotProxy` value from the DB directly: ```sql UPDATE settings SET value = '' WHERE key = 'tgBotProxy'; ``` (Run against `/etc/x-ui/x-ui.db` via `sqlite3`, then restart `x-ui`.) After that the bot will use `panelProxy`. ## Summary - **New installs**: configure the proxy via **Settings → General → Panel Network Proxy** — that setting explicitly covers Telegram. - **Existing installs**: old `tgBotProxy` values still work; optionally migrate using the steps above. The remaining gap is that the Telegram settings tab gives no indication that its proxy lives in General settings, which can confuse users. That would be worth a small UI hint or tooltip on the Telegram tab.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
MHSanaei/3x-ui#3402
No description provided.