Deploy a single VPS that connects through multiple countries simultaneously
X-UI-PRO transforms a single VPS into a multi-country proxy server. Using the power of Psiphon technology, you can create VPN configurations that exit through 5 different countries simultaneously - all from one server.
| Feature | Description |
|---|---|
| 🌍 Multi-Country Exit | 5 concurrent Psiphon instances (ports 8080-8084), each in a different country |
| 🔒 Full TLS Security | All traffic encrypted with Let's Encrypt SSL certificates |
| 🌐 Cloudflare Compatible | Works behind Cloudflare CDN for additional protection |
| 🎛️ X-UI Panel | Beautiful web interface for managing VPN configurations |
| 🔄 Auto-Recovery | Services auto-restart on failure with health monitoring |
| 📊 Real-time Monitoring | Live dashboard showing all instance statuses |
┌─────────────────────────────────────────┐
│ YOUR SINGLE VPS │
│ │
│ ┌─────────────────────────────────┐ │
│ │ X-UI Panel │ │
│ │ (Create VPN Configs) │ │
┌──────────────┐ │ └─────────────────────────────────┘ │
│ Client │ ──── HTTPS ────▶ │ │ │
│ (Your Users) │ Port 443 │ ▼ │
└──────────────┘ │ ┌─────────────────────────────────┐ │
│ │ NGINX Reverse Proxy │ │
│ │ (SSL Termination + Routing) │ │
│ └─────────────────────────────────┘ │
│ │ │
│ ┌─────────────┼─────────────┐ │
│ ▼ ▼ ▼ │
│ ┌──────┐ ┌──────┐ ┌──────┐ │
│ │:8080 │ │:8081 │ │:8082 │ │
│ │ US │ │ DE │ │ GB │ │
│ └──┬───┘ └──┬───┘ └──┬───┘ │
│ │ │ │ │
│ ┌──────┐ ┌──────┐ │
│ │:8083 │ │:8084 │ │
│ │ NL │ │ FR │ │
│ └──┬───┘ └──┬───┘ │
└────┼───────────┼───────────────────────┘
│ │
▼ ▼
┌─────────────────────────────────────┐
│ INTERNET (Multiple Countries) │
│ 🇺🇸 US 🇩🇪 DE 🇬🇧 GB 🇳🇱 NL 🇫🇷 FR │
└─────────────────────────────────────┘
- A VPS running Ubuntu 20.04+ or Debian 11+ or CentOS 8+
- A domain name pointed to your VPS IP
- Root/sudo access
- Minimum 1GB RAM, 10GB storage
sudo su -c "bash <(wget -qO- raw.githubusercontent.com/rezasmind/x-ui-pro/master/x-ui-pro.sh) -panel 0"During installation, you'll be asked:
- Enter your subdomain (e.g.,
vpn.yourdomain.com) - Choose SSL method (standalone or Cloudflare DNS)
- Answer
ywhen asked about Multi-Port Psiphon - Select a country for each port (8080-8084)
After installation, check that all instances are running:
./check-psiphon.shOr use the detailed management tool:
./deploy-psiphon.sh status- Access your panel at:
https://yourdomain.com/your-secret-path/ - Login with the credentials shown after installation
- Create inbound configurations (see detailed guide below)
Go to: X-UI Panel → Xray Configs → Outbounds → Add Outbound
Create 5 SOCKS outbounds, one for each Psiphon instance:
| Outbound Name | Protocol | Address | Port |
|---|---|---|---|
| psiphon-US | SOCKS | 127.0.0.1 | 8080 |
| psiphon-DE | SOCKS | 127.0.0.1 | 8081 |
| psiphon-GB | SOCKS | 127.0.0.1 | 8082 |
| psiphon-NL | SOCKS | 127.0.0.1 | 8083 |
| psiphon-FR | SOCKS | 127.0.0.1 | 8084 |
Example configuration:
{
"tag": "psiphon-US",
"protocol": "socks",
"settings": {
"servers": [
{
"address": "127.0.0.1",
"port": 8080
}
]
}
}Go to: X-UI Panel → Inbounds → Add Inbound
Create an inbound for each country. Example for VLESS + WebSocket:
| Setting | Value |
|---|---|
| Protocol | VLESS |
| Port | 443 (shared via nginx) |
| Transport | WebSocket |
| Path | /us-config (unique per config) |
| TLS | Enabled |
Go to: X-UI Panel → Xray Configs → Routing Rules → Add Rule
Create routing rules to connect specific inbounds to their Psiphon outbounds:
| Inbound Tag | Outbound Tag | Result |
|---|---|---|
| us-inbound | psiphon-US | Traffic exits via US IP |
| de-inbound | psiphon-DE | Traffic exits via Germany IP |
| gb-inbound | psiphon-GB | Traffic exits via UK IP |
# Check status of all instances
./deploy-psiphon.sh status
# Live monitoring dashboard
./deploy-psiphon.sh monitor
# View logs for specific port
./deploy-psiphon.sh logs 8080
# Restart all instances
./deploy-psiphon.sh restart
# Restart specific instance
./deploy-psiphon.sh restart 8081
# Stop all instances
./deploy-psiphon.sh stop
# Reconfigure all instances (change countries)
./deploy-psiphon.sh
# Uninstall Psiphon instances
./deploy-psiphon.sh uninstall./check-psiphon.sh# Single country
bash <(wget -qO- raw.githubusercontent.com/rezasmind/x-ui-pro/master/x-ui-pro.sh) -WarpCfonCountry US
# Random country
bash <(wget -qO- raw.githubusercontent.com/rezasmind/x-ui-pro/master/x-ui-pro.sh) -WarpCfonCountry XX# Set Tor exit country
bash <(wget -qO- raw.githubusercontent.com/rezasmind/x-ui-pro/master/x-ui-pro.sh) -TorCountry US
# Random Tor country
bash <(wget -qO- raw.githubusercontent.com/rezasmind/x-ui-pro/master/x-ui-pro.sh) -TorCountry XXUse these 2-letter codes when configuring Psiphon instances:
| Code | Country | Code | Country | Code | Country |
|---|---|---|---|---|---|
| AT | Austria | HU | Hungary | PL | Poland |
| AU | Australia | IE | Ireland | PT | Portugal |
| BE | Belgium | IN | India | RO | Romania |
| BG | Bulgaria | IT | Italy | RS | Serbia |
| BR | Brazil | JP | Japan | SE | Sweden |
| CA | Canada | LV | Latvia | SG | Singapore |
| CH | Switzerland | NL | Netherlands | SK | Slovakia |
| CZ | Czechia | NO | Norway | UA | Ukraine |
| DE | Germany | GB | United Kingdom | US | United States |
| DK | Denmark | ||||
| EE | Estonia | ||||
| ES | Spain | ||||
| FI | Finland | ||||
| FR | France | ||||
| HR | Croatia |
sudo su -c "bash <(wget -qO- raw.githubusercontent.com/rezasmind/x-ui-pro/master/x-ui-pro.sh) -panel 0"sudo su -c "bash <(wget -qO- raw.githubusercontent.com/rezasmind/x-ui-pro/master/x-ui-pro.sh) -panel 0 -cdn on"# Only allow connections from specific countries
sudo su -c "bash <(wget -qO- raw.githubusercontent.com/rezasmind/x-ui-pro/master/x-ui-pro.sh) -panel 0 -cdn on -country us,de,gb"sudo su -c "bash <(wget -qO- raw.githubusercontent.com/rezasmind/x-ui-pro/master/x-ui-pro.sh) -panel 0 -cdn on -secure yes"| Argument | Values | Description |
|---|---|---|
-panel |
0, 1, 2, 3 | X-UI variant (0=Alireza, 1=MHSanaei, 2=FranzKafkaYu, 3=AghayeCoder) |
-xuiver |
version/last | X-UI version to install |
-subdomain |
domain | Your subdomain |
-cdn |
on/off | Cloudflare CDN mode |
-secure |
yes/no | Enhanced security mode |
-country |
XX/codes | Country restrictions |
-ufw |
on | Enable UFW firewall |
-WarpCfonCountry |
code | WARP+Psiphon country |
-WarpLicKey |
key | WARP+ license key |
-TorCountry |
code | Tor exit node country |
-RandomTemplate |
yes | Random fake website template |
-Uninstall |
yes | Uninstall X-UI-PRO |
-
Wait for initialization: First startup can take 1-3 minutes
# Watch the status in real-time ./deploy-psiphon.sh monitor -
Check service logs:
./deploy-psiphon.sh logs 8080 # or journalctl -u psiphon-8080 -f -
Restart specific instance:
./deploy-psiphon.sh restart 8080
-
Restart all instances:
./deploy-psiphon.sh restart
# Force renewal
certbot renew --force-renewal
# Check certificate status
certbot certificates# Test configuration
nginx -t
# Restart nginx
systemctl restart nginx# X-UI Panel
systemctl status x-ui
# Nginx
systemctl status nginx
# Psiphon instances
./check-psiphon.sh| Port | Service | Description |
|---|---|---|
| 80 | Nginx | HTTP (redirects to HTTPS) |
| 443 | Nginx | HTTPS (main entry point) |
| 2017 | v2rayA | v2rayA Web Panel |
| 2053+ | X-UI | X-UI Panel (internal) |
| 8080 | Psiphon | Instance #1 (Country 1) |
| 8081 | Psiphon | Instance #2 (Country 2) |
| 8082 | Psiphon | Instance #3 (Country 3) |
| 8083 | Psiphon | Instance #4 (Country 4) |
| 8084 | Psiphon | Instance #5 (Country 5) |
| 8086 | WARP | Single WARP instance (if not using multi-Psiphon) |
| 9050 | Tor | Tor SOCKS proxy |
- Always use HTTPS (port 443) for client connections
- Enable UFW firewall:
bash <(wget -qO- raw.githubusercontent.com/rezasmind/x-ui-pro/master/x-ui-pro.sh) -ufw on - Change default SSH port:
sudo bash -c 'read -p "Enter new SSH port: " port && sed -i "s/^#Port 22/Port $port/" /etc/ssh/sshd_config && ufw allow ${port}/tcp && systemctl restart sshd' - Use Cloudflare CDN for additional protection
- Regularly update your VPS and X-UI panel
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the MIT License.
- x-ui panels - Original X-UI developers
- warp-plus - WARP/Psiphon implementation
- v2rayA - v2rayA project
⭐ Star this repo if you find it useful! ⭐
