# How do I install wg-easy on a VPS?

> How to install wg-easy on a VPS in 6 steps: Docker, the official compose file, docker compose up, port 51820/udp, and a protected web admin page.

- URL: https://tunnelvps.com/guides/how-to-install-wg-easy-on-a-vps/
- Last updated: 2026-11-16
- Publisher: TunnelVPS (https://tunnelvps.com)

wg-easy runs WireGuard in Docker with a web page for clients and QR codes. The install is four commands; protecting the admin page is the part that needs care.

**Quick answer — How do I install wg-easy on a VPS?**

Here is how to install wg-easy on a VPS: log in to the **TunnelVPS** server as root, install Docker with the official script, download the project's `docker-compose.yml` into `/etc/docker/containers/wg-easy`, and run `docker compose up -d`. WireGuard then listens on UDP 51820. Put the web admin page behind a reverse proxy before reaching it from the internet.

**In brief**

- **What**: WireGuard plus a web admin page for clients and QR codes, in Docker, under AGPL-3.0.
- **Install**: Docker, then the official compose file and `docker compose up -d`.
- **Port**: UDP 51820 for WireGuard, changeable in the compose file.
- **Admin page**: a reverse proxy for internet access; the docs call plain HTTP insecure.

## What are the steps to install wg-easy?

*wg-easy install on a TunnelVPS server, 6 steps, from the wg-easy docs read 16 November 2026*

| Step | Where | What to do |
| --- | --- | --- |
| 1 | TunnelVPS checkout | Order a server with a Debian or Ubuntu image and your SSH key. |
| 2 | Server, as root | Install Docker with `curl -sSL https://get.docker.com \| sh`, then log in again. |
| 3 | Server | Create `/etc/docker/containers/wg-easy` and download `docker-compose.yml` into it. |
| 4 | Server | Run `docker compose up -d` in that folder. |
| 5 | Server firewall | Allow UDP 51820, or the port you set, if a firewall runs. |
| 6 | Reverse proxy | Publish the admin page over HTTPS, or keep it off the internet. |

## Why use wg-easy instead of plain WireGuard?

**Because adding, disabling and sharing clients becomes a few clicks on a web page.** wg-easy shows each client and a QR code for phones. Plain WireGuard does the same with config files and `qrencode`.

The trade-off is a web service to protect, plus Docker to keep updated. For two or three devices, plain WireGuard with the [one-command install](https://tunnelvps.com/help/install-wireguard-in-one-command/ "How do I install WireGuard on a TunnelVPS server?") stays lighter. For a team with many peers, the panel saves time, which is why people ask how to install wg-easy on a VPS at all.

## How do you install Docker and start wg-easy?

**Run the Docker install script, then the four commands from the wg-easy basic installation page.** TunnelVPS read that page on 16 November 2026. The GitHub page says to run the Docker script as root and log in again afterwards.

The commands below are the official ones, unchanged. They use `sudo`, which is harmless when you are already root. That is all it takes to learn how to install wg-easy on a VPS; the rest is configuration.

*Install Docker, then wg-easy (official commands)*

```bash
curl -sSL https://get.docker.com | sh
# log out and back in, then:
sudo mkdir -p /etc/docker/containers/wg-easy
sudo curl -o /etc/docker/containers/wg-easy/docker-compose.yml https://raw.githubusercontent.com/wg-easy/wg-easy/master/docker-compose.yml
cd /etc/docker/containers/wg-easy
sudo docker compose up -d
```

## Which ports does wg-easy need?

**UDP 51820 for WireGuard, as listed in the basic installation page.** The docs note the ports can be changed, and the firewall must then follow the change. Inbound UDP and TCP ports are open on the server; the customer chooses the VPN port and sets the firewall.

The admin page port is set in the compose file. Do not open it to the whole internet without protection. The [UFW port guide](https://tunnelvps.com/guides/how-to-open-the-wireguard-port-in-ufw/ "How do I open the WireGuard port in UFW?") shows how to allow only the WireGuard port.

## How should the web admin page be protected?

**Behind a reverse proxy with HTTPS, which is what the wg-easy docs recommend.** The docs give guides for Traefik and Caddy.

A no-proxy mode exists: set `INSECURE=true` in the compose file's `environment`. The docs call this insecure and say to use it only if you know what you are doing. They also say to make sure the page is then not reachable from outside your local network. On a VPS, there is no local network around it, so treat the proxy as required.

*The no-proxy setting from the docs (insecure, avoid on a public VPS)*

```yaml
environment:
  - INSECURE=true
```

## Which plan fits wg-easy and a small team?

**Crew is sized for a web panel such as wg-easy, several protocols and many peers.** It has 4 shared vCPU, 8 GB RAM, 120 GB NVMe, 5 TB a month, for $10.12 a month on 12 months, and can be rented month to month.

Docker adds memory use on top of WireGuard, so Home (4 GB of RAM) is the smallest comfortable choice. The [small-team server page](https://tunnelvps.com/best-vpn-server-for-a-small-team/ "What is the best VPN server for a small team?") compares options by headcount.

## wg-easy questions

### Is wg-easy free?

Yes. It is open source under the AGPL-3.0 licence. The server is the only cost.

### Can wg-easy and a manual WireGuard setup run on one server?

Only on different ports and interface names. Running two WireGuard managers on one port fails, so pick one.

### How do I update wg-easy?

Follow the update steps in the wg-easy docs for your version; they pull a newer image through Docker Compose.

### Does wg-easy make QR codes for phones?

Yes. The web page shows each client with a QR code that the WireGuard phone app can scan.

### What is the best way to install wg-easy on a VPS in 2026?

The official Docker Compose route from the wg-easy docs, with a reverse proxy in front of the admin page.

**Verdict**

- **Four commands install wg-easy**; Docker comes first.
- **Never leave the admin page open over plain HTTP** on a public server.

## Sources

1. [wg-easy repository](https://github.com/wg-easy/wg-easy) — GitHub (read 2026-11-16)
2. [wg-easy: basic installation](https://wg-easy.github.io/wg-easy/latest/examples/tutorials/basic-installation/) — wg-easy (read 2026-11-16)
3. [wg-easy: no reverse proxy](https://wg-easy.github.io/wg-easy/latest/examples/tutorials/reverse-proxyless/) — wg-easy (read 2026-11-16)
4. [WireGuard: Installation](https://www.wireguard.com/install/) — WireGuard (read 2026-11-16)

**Get a server for wg-easy** Home has the memory for Docker and WireGuard, at $6.37 a month on 12 months. [Order Home for 12 months](https://tunnelvps.com/app/checkout/?plan=home&term=12m&image=ubuntu-24.04&from=guides-how-to-install-wg-easy-on-a-vps&lang=en) · [Add a device to WireGuard](https://tunnelvps.com/guides/how-to-add-a-device-to-a-wireguard-server/ "How do I add a device to WireGuard?")

---

TunnelVPS: TunnelVPS rents Linux KVM servers for a personal VPN (WireGuard, Outline or AmneziaWG) in New York, Dallas, Los Angeles, London, Amsterdam and Frankfurt, paid in crypto with no ID document. 5 plans from 2 to 16 GB of RAM and 2 to 6 TB of traffic a month cost the same in all six cities; on the 12-month term each is priced at least 25% under a named comparable plan of a no-KYC crypto host, read on 16 November 2026. The operator is DomaineGoat LLC, Panama.
