3AX-UI is a fork of 3x-ui that hides your server behind a single port 443 and extends AmneziaWG: public IPv6 without NAT, port forwarding and routing through Xray on the fast kernel module.
The A in the name stands for Amnezia — the protocol this fork started with.
Important
This project is intended for personal use only. Please do not use it for illegal purposes.
bash <(curl -Ls https://raw.githubusercontent.com/coinman-dev/3ax-ui/main/install.sh)To install the latest pre-release version:
bash <(curl -Ls https://raw.githubusercontent.com/coinman-dev/3ax-ui/main/install.sh) --beta3AX-UI 2.x is built on 3x-ui 3.11.0. Everything the original has is here: VLESS, VMess, Trojan, Shadowsocks, AmneziaWG 3.1, MTProto, TUIC, clients shared between inbounds, nodes, hosts, subscriptions, PostgreSQL, the Telegram and Discord bots. Earlier 1.x releases had their own AmneziaWG, WireGuard and MTProto; 2.x uses the upstream implementations and adds what they lack:
- an nginx front-end on port 443 with a cover website;
- public IPv6, port forwarding and Xray routing for kernel-mode AmneziaWG;
- SOCKS5/HTTP clients with their own quota, expiry and statistics;
- an automatic upgrade from 3AX-UI 1.x that keeps your clients and links.
The problem it solves. A panel on one port, Reality on 443, subscriptions on a third, MTProto on a fourth — that is a shape. A scanner finds several ports speaking TLS to nobody in particular, and a browser opening the domain finds nothing at all. Meanwhile plenty of networks let 443 through and very little else.
What it does. nginx takes port 443 and reads the server name straight out of the TLS handshake without decrypting anything (stream + ssl_preread), then hands the connection to whichever inbound announced that name. Reality's TLS stays end to end — the panel never sits in the middle of it. Anyone who arrives without a name the server recognises is given an ordinary website.
Three modes on the Nginx camouflage page:
| Mode | What happens |
|---|---|
| Off | Every inbound keeps its own port. Nothing on the page is applied. |
| Dual mode | The inbound that was on 443 moves to the loopback. Every other inbound keeps its own port and answers on 443 as well, so links already handed out go on working — nothing has to be re-issued. |
| Port 443 only | Nothing is left on a port of its own, and the ports nobody needs any more are closed. |
A cover page, not an empty port. The domain is served a real website: one of three built-in templates or your own single-file HTML, chosen from a gallery of live previews, edited in the panel and stored in the database — so it rides along in the backup and survives a reinstall. Only the active one is written to disk for nginx to serve.
The panel and the subscriptions can live there too. Both can be published on the same domain over 443, each at its own path — two fewer ports to explain. The subscription server keeps its own port as well, so links already handed out do not break; new ones carry the new address.
Closing ports is a lease, not a leap. SSH stays open, on whatever port sshd's own configuration says. So do the UDP tunnels, DHCP, anything arriving through a tunnel interface, the replies to whatever the server itself asked for, and any extra ports you name. TCP 80 stays open too: certificate renewal needs it. Then you have two minutes to confirm from the panel that it is still reachable — if nobody does, it all comes back on its own. The deadline is stored in the database, so restarting the panel does not lose it.
Nothing moves until you have read what moves. Applying shows a plan first: which inbound goes where, which links change port, whether the subscription address changes, what stays open, and what would be cut off because it announces no server name at all.
AmneziaWG and other UDP inbounds cannot share a TCP port, so they keep their own ports in every mode.
When nodes are used, nginx routes only the inbounds of the panel's own server.
Needs nginx with the stream module — the panel checks and says so — and a certificate for the domain.
3x-ui runs AmneziaWG either in a built-in userspace stack or on the kernel module. In 3AX-UI kernel mode also supports:
- a public IPv6 address for every client, without NAT66 (NDP proxy, no
ndppdneeded); - per-client port forwarding: single ports and ranges, TCP and UDP;
- routing through Xray (TPROXY), so routing rules apply to the tunnel; the rules are restored if the system drops them.
The panel warns when an obfuscation set loses packets: RandomTrailers with wide H1–H4 ranges drops large packets, and one button switches to safe values.
Kernel mode needs the amneziawg kernel module, amneziawg-tools and nftables on the server. Without them the built-in stack works, and the panel lists what is missing.
NDP proxy may not work on a VPS for reasons outside your server's control:
1. Hypervisor blocks NDP packets (MAC filtering)
Many providers allow a VPS to send packets only from its own network interface MAC address. When the NDP proxy forwards a Neighbor Advertisement on behalf of a client, the hypervisor treats this as IP spoofing and drops the packet. Everything looks correct inside the VPS, but client IPv6 traffic never reaches the internet.
2. Provider assigns a "link prefix" instead of a "routed prefix"
NDP proxy only works when the IPv6 block is routed directly to your VPS. Many providers connect multiple VPSes to a shared virtual network and assign addresses from a common pool — in this case, NDP proxy at the VPS level won't help.
Contact your provider's support. You need to find out:
- IPv6 allocation type: is it a fully routed /64 prefix (routed to your VM) or an address from a shared pool (link prefix)? Only a routed prefix allows NDP proxy to work.
- Hypervisor-level NDP proxy: does the control panel have an option to enable NDP proxy / Neighbor Discovery at the host level?
- IP spoofing allowance: ask them to allow NDP packet forwarding from your VPS (disable MAC filtering for your interface at the hypervisor level).
Message template for provider support: "I'm running a server with multiple virtual network interfaces and need to assign individual public IPv6 addresses from my /64 block to each of them using NDP proxy. Could you please confirm whether my IPv6 allocation is a fully routed /64 prefix routed to my VM directly, and whether NDP Neighbor Advertisement packets originated from my VM are allowed through the hypervisor — or if they are dropped by MAC/ARP filtering on the host node?"
mixed (SOCKS5) and http inbounds use the same clients as VLESS or Trojan: traffic, quota, expiry and an on/off switch for each user.
Extra anti-blocking options for the mtg-multi sidecar in the inbound form, plus its state and version on the dashboard.
The 1.x layout, as an option in Panel Settings. It is on after an upgrade from 1.x and off on a new installation.
install.shinstalls nginx with thestreammodule and gives subscriptions a random path.- Run from a git clone,
install.shandupdate.shbuild the panel from the local sources:
git clone https://github.com/coinman-dev/3ax-ui.git
cd 3ax-ui
sudo bash install.sh- Debug mode (a question at install time, or
XUI_DEBUG_MODE=1): the panel listens on127.0.0.1over HTTP only;XUI_DEBUG_PORTsets the port. - QR code size: 300, 450 or 600 px.
# Stable release
bash <(curl -Ls https://raw.githubusercontent.com/coinman-dev/3ax-ui/main/install.sh)
# Latest pre-release
bash <(curl -Ls https://raw.githubusercontent.com/coinman-dev/3ax-ui/main/install.sh) --beta
# Specific version
bash <(curl -Ls https://raw.githubusercontent.com/coinman-dev/3ax-ui/main/install.sh) v2.0.0# Stable release
bash <(curl -Ls https://raw.githubusercontent.com/coinman-dev/3ax-ui/main/update.sh)
# Latest pre-release
bash <(curl -Ls https://raw.githubusercontent.com/coinman-dev/3ax-ui/main/update.sh) --betaBack up the server first (a VPS snapshot, or at least /etc/x-ui/x-ui.db), then run x-ui update. The data moves over automatically, and the panel saves a copy of the old database next to it (x-ui.db.3ax-1x-backup-*).
- AmneziaWG and WireGuard servers become AmneziaWG inbounds in kernel mode. WireGuard keeps working without obfuscation, and clients connect without re-importing.
- MTProto and SOCKS5/HTTP clients, traffic, limits and nginx settings are kept.
- A name used by several protocols gets a suffix:
-awg,-wgor-mtproto. - Old awg-quick / wg-quick tunnels are stopped; their configs stay as
*.3ax-1x-bak. - Not carried over: split-tunnelling AllowedIPs of clients and your own PostUp/PostDown commands.
- If the panel shows a packet-loss warning on an AmneziaWG inbound, apply the fix and hand out new configs to its clients.
- Inbounds → Add Inbound → protocol amneziawg; the obfuscation set is generated for you
- Turn on Kernel mode if the module is installed on the server
- Add a client and attach it to the inbound
- Scan the client's QR code in AmneziaVPN, or download the config
- Inbounds → Add Inbound → protocol MTProto, set the port and a fronting domain
- Add a client and attach it to the inbound
- Open the client's
tg://link: Telegram offers to enable the proxy
| Protocol | Client | Platforms |
|---|---|---|
| AmneziaWG | AmneziaVPN — amnezia.org | Android, iOS, Windows, macOS, Linux |
| AmneziaWG without obfuscation | Official WireGuard | All platforms |
| MTProto | Telegram (built-in proxy support) | All platforms |
Standard WireGuard clients do not support obfuscation parameters.
- OS: Ubuntu 22.04+ / Debian 11+ recommended; other distributions work as in 3x-ui
- RAM: 1024 MB or more
- Architecture: tested on amd64. Builds for arm64, armv7, armv6, armv5, 386, s390x and Windows are published but not tested
Secure Boot: the AmneziaWG DKMS module may fail to load with Secure Boot on.
3AX-UI is based on 3x-ui by MHSanaei. MTProto runs on the mtg-multi sidecar.
- MHSanaei — author of 3x-ui
- alireza0 — author of the original x-ui
- 9seconds/mtg and dolonet/mtg-multi — MTProto sidecars
- Iran v2ray rules (GPL-3.0)
- Russia v2ray rules (GPL-3.0)
This project is distributed under the same license as the original 3x-ui — GNU GPL v3.