Self-host RustDesk
An open-source remote-desktop app (a TeamViewer/AnyDesk-style tool) plus the self-hostable ID/rendezvous server (hbbs) and relay (hbbr) behind it. Running your own pair means clients register and relay through your VPS instead of RustDesk's public servers; the free OSS server has no web console, accounts or address book (those are RustDesk Server Pro).
Key facts
Pick RustDesk when you want TeamViewer- or AnyDesk-style remote desktop access without sending your sessions through someone else's servers: run the free hbbs (ID/rendezvous) and hbbr (relay) pair on a small VPS and point the RustDesk clients at it. Despite sitting in the VPN & mesh category, it is not a VPN — it relays remote-desktop sessions, not network traffic; for that, look at Headscale or NetBird instead.
What you need
- Any VPS with at least 256 MB of RAM
- A domain you control — most self-hosted setups need HTTPS in front of them
- Under an hour if you've used Docker before
Paid link — we earn a commission if you shop through it.
Install
Run these commands on your server:
# RustDesk Server OSS (hbbs + hbbr) — official image pinned to the latest release, host networking as the docs recommend on Linux
mkdir -p ~/rustdesk && cd ~/rustdesk
cat > compose.yml <<'EOF'
services:
hbbs:
container_name: hbbs
image: rustdesk/rustdesk-server:1.1.16
command: hbbs
volumes:
- ./data:/root
network_mode: host
depends_on:
- hbbr
restart: unless-stopped
hbbr:
container_name: hbbr
image: rustdesk/rustdesk-server:1.1.16
command: hbbr
volumes:
- ./data:/root
network_mode: host
restart: unless-stopped
EOF
docker compose up -d
# open TCP 21115-21117 and UDP 21116 (21118/21119 only for the web client, behind a reverse proxy)
sleep 5 && cat data/id_ed25519.pub
# in each RustDesk client: ID server = SERVER_IP, Key = the public key printed aboveWhat you take on
The open-source server is deliberately small, and upstream is open about where the paid edition starts: