Self-host Headscale
An open-source, self-hosted implementation of the Tailscale control server — run your own coordination plane for a private WireGuard mesh and keep using the official Tailscale clients, without depending on Tailscale's hosted service.
Key facts
Pick Headscale when you already like the Tailscale clients and the only thing you refuse to rent is the coordination server: it is a BSD-3-Clause Go binary with SQLite by default that implements a single tailnet — MagicDNS, ACLs and grants, subnet routers and exit nodes, an embedded DERP relay and OIDC registration are all on the features list — and the README scopes it at "personal use, or a small open-source organisation". There is no built-in web interface; the admin surface is the `headscale` CLI, with community UIs listed in the docs. If you want a mesh product with its own dashboard and users, that is NetBird.
Follow the Headscale deploy guide →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
- About an afternoon — budget time for troubleshooting
Paid link — we earn a commission if you shop through it.
Install
Run these commands on your server:
# Headscale — control server only (no web UI); needs a config.yaml + TLS on 443
mkdir -p ./headscale/config ./headscale/data && cd ./headscale
curl -fsSL -o config/config.yaml https://raw.githubusercontent.com/juanfont/headscale/main/config-example.yaml
# Required edits: set server_url to your https:// URL, and change
# listen_addr from 127.0.0.1:8080 to 0.0.0.0:8080 or the port won't publish.
docker run --name headscale -d -p 443:8080 \
-v $(pwd)/config:/etc/headscale -v $(pwd)/data:/var/lib/headscale \
headscale/headscale:stable serveWhat you take on
Headscale is small and well documented, but its maintainers are unusually explicit about what they do and do not support:
An alternative to
Head-to-head
The same Tailscale apps — but who runs the coordination server?
An all-in-one mesh vs. your own Tailscale control plane.
The simplest WireGuard VPN vs. your own Tailscale mesh.