[GH-ISSUE #4990] [Question]: How to set up reverse tunnel in new UI #3508

Closed
opened 2026-10-31 20:32:56 +07:00 by bsakaguchi · 3 comments
Owner

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

What are you trying to do?

I'm trying to set up reverse tunnel in new UI. I want to know the step by step instruction.

What have you already tried?

i have seen the related video on youtube but for me it does not work.

3x-ui version

3.2.5

How did you install 3x-ui?

install.sh script

Operating system

Ubuntu 24

Screenshots or config snippets

No response

Before submitting

  • I read the Wiki and searched existing issues.
  • This is a usage question, not a bug report.
  • This question is written in English.
Originally created by @RezaHaghgoo on GitHub (Jun 5, 2026). Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/4990 ### What are you trying to do? I'm trying to set up reverse tunnel in new UI. I want to know the step by step instruction. ### What have you already tried? i have seen the related video on youtube but for me it does not work. ### 3x-ui version 3.2.5 ### How did you install 3x-ui? install.sh script ### Operating system Ubuntu 24 ### Screenshots or config snippets _No response_ ### Before submitting - [x] I read the [Wiki](https://github.com/MHSanaei/3x-ui/wiki) and searched [existing issues](../issues?q=is%3Aissue). - [x] This is a usage question, not a bug report. - [x] This question is written in English.
bsakaguchi 2026-10-31 20:32:56 +07:00
  • closed this issue
  • added the
    question
    label
Author
Owner

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

The most likely reason your reverse tunnel isn't working on v3.2.5 is a known bug that was fixed in v3.2.7: xray-core v26.5+ tightened the default Freedom outbound finalRules, which silently blocks all egress for VLESS reverse-proxy traffic on existing installs. The panel now ships with a migration that automatically relaxes those rules on startup.

Step 1 — Upgrade to v3.2.7 or later (required)

bash <(curl -Ls https://raw.githubusercontent.com/mhsanaei/3x-ui/master/install.sh)

After upgrading, the startup migration will fix the Freedom outbound's finalRules automatically. Then restart:

systemctl restart x-ui

Step 2 — Configure the reverse tunnel in the new UI

The feature uses a Reverse Tag field on a VLESS client, not a separate "reverse" section. Here is the general flow:

On the portal server (the server clients connect to directly):

  1. Create a VLESS inbound for the bridge server to connect in to (e.g., on port 443 with REALITY or TLS).
  2. Create a VLESS outbound (or use an existing one) that routes traffic to the intended destination.
  3. In Routing, add a rule: traffic from the reverse inbound tag → outbound toward the destination.

On the bridge server (behind NAT / the Iran-side server):

  1. Create a VLESS outbound pointing to the portal server.
  2. In the client settings for that outbound, open the client editor and set a Reverse Tag (e.g., reverse-bridge). This is the reverse → tag field in the model — it tells xray this outbound is the bridge side of a reverse tunnel.
  3. In Routing, add a rule: inboundTag matching the Reverse Tag → forward to the Freedom outbound.

The Reverse Tag field is under the client settings when editing a VLESS outbound client. GetClientReverseTags in the panel collects all configured reverse tags and makes them available in the routing UI.


If it still doesn't work after upgrading, please share:

  • The xray-core version in use (Panel → Xray Configuration → Core version)
  • The relevant xray logs (Panel → Logs → Xray)
  • Whether you see context deadline exceeded in the logs (indicates the burstObservatory timing issue from #4782)

References: fix landed in v3.2.7 — fix(xray): default freedom finalRules, fix(migrate): relax legacy freedom finalRules (#4782).

<!-- gh-comment-id:4635991873 --> @github-actions[bot] commented on GitHub (Jun 5, 2026): The most likely reason your reverse tunnel isn't working on v3.2.5 is a known bug that was fixed in **v3.2.7**: xray-core v26.5+ tightened the default Freedom outbound `finalRules`, which silently blocks all egress for VLESS reverse-proxy traffic on existing installs. The panel now ships with a migration that automatically relaxes those rules on startup. **Step 1 — Upgrade to v3.2.7 or later (required)** ```bash bash <(curl -Ls https://raw.githubusercontent.com/mhsanaei/3x-ui/master/install.sh) ``` After upgrading, the startup migration will fix the Freedom outbound's `finalRules` automatically. Then restart: ```bash systemctl restart x-ui ``` --- **Step 2 — Configure the reverse tunnel in the new UI** The feature uses a **Reverse Tag** field on a VLESS client, not a separate "reverse" section. Here is the general flow: **On the portal server (the server clients connect to directly):** 1. Create a VLESS inbound for the bridge server to connect in to (e.g., on port 443 with REALITY or TLS). 2. Create a VLESS outbound (or use an existing one) that routes traffic to the intended destination. 3. In **Routing**, add a rule: traffic from the reverse inbound tag → outbound toward the destination. **On the bridge server (behind NAT / the Iran-side server):** 1. Create a VLESS outbound pointing to the portal server. 2. In the client settings for that outbound, open the client editor and set a **Reverse Tag** (e.g., `reverse-bridge`). This is the `reverse` → `tag` field in the model — it tells xray this outbound is the bridge side of a reverse tunnel. 3. In **Routing**, add a rule: `inboundTag` matching the Reverse Tag → forward to the Freedom outbound. > The **Reverse Tag** field is under the client settings when editing a VLESS outbound client. `GetClientReverseTags` in the panel collects all configured reverse tags and makes them available in the routing UI. --- **If it still doesn't work after upgrading**, please share: - The xray-core version in use (Panel → Xray Configuration → Core version) - The relevant xray logs (Panel → Logs → Xray) - Whether you see `context deadline exceeded` in the logs (indicates the `burstObservatory` timing issue from #4782) References: fix landed in v3.2.7 — [fix(xray): default freedom finalRules](https://github.com/MHSanaei/3x-ui/commit/8f5a7b94), [fix(migrate): relax legacy freedom finalRules (#4782)](https://github.com/MHSanaei/3x-ui/commit/6f6c7fc1).
Author
Owner

@RezaHaghgoo commented on GitHub (Jun 5, 2026):

what do you mean by "forward to the Freedom outbound". tell the details

<!-- gh-comment-id:4636266211 --> @RezaHaghgoo commented on GitHub (Jun 5, 2026): what do you mean by "forward to the Freedom outbound". tell the details
Author
Owner

@MHSanaei commented on GitHub (Jun 6, 2026):

ask your question https://github.com/MHSanaei/3x-ui/discussions

<!-- gh-comment-id:4636638355 --> @MHSanaei commented on GitHub (Jun 6, 2026): ask your question https://github.com/MHSanaei/3x-ui/discussions
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#3508
No description provided.