VPNSmith
self-host-vpnCOMP

Headscale vs WireGuard (2026): One Is the Tunnel, the Other Hands Out the Keys

Headscale does not replace WireGuard: it coordinates it. Plain WireGuard means writing every peer by hand; Headscale distributes keys, addresses and routes to Tailscale clients. What each one requires, what Headscale's own documentation says it is not, and how to choose.

By Eric Gerard · Founder · VPNSmith - Self-host VPN & GDPR VPS specialist8 min readPhoto via Pexels

Affiliate disclosure - This article contains a Contabo affiliate link. If you order a VPS via our link, we earn a commission at no extra cost to you. Facts about Headscale and WireGuard below were read in each project's official documentation on 8 October 2026.

Quick answer: "Headscale vs WireGuard" is not a choice between two VPN protocols. WireGuard is the tunnel. Headscale is a control server that tells Tailscale clients which WireGuard keys, addresses and routes to use, so that you do not write them by hand. Take plain WireGuard if you have one server and a handful of devices that only need to reach that server. Take Headscale if you want many devices to reach each other, across NAT, with names, access rules and no configuration file to edit on each machine.

Two layers, not two rivals

The WireGuard project describes what it does in one sentence: it "securely encapsulates IP packets over UDP". You add an interface, give it your private key and your peers' public keys, and packets flow. The same page is just as clear about what it leaves out: "All issues of key distribution and pushed configurations are out of scope of WireGuard".

That missing layer is exactly what Headscale provides. Its README defines it as "an open source, self-hosted implementation of the Tailscale control server", and describes the control server as the exchange point of WireGuard public keys for the nodes of the network: it assigns the IP addresses of the clients and exposes the routes they advertise.

So the real comparison is this:

  • Plain WireGuard: you are the control plane. You generate keys, pick addresses, write each [Peer] block and copy it to both ends.
  • Headscale: a service you host is the control plane. Devices run the Tailscale client, log in to your server, and receive their peers automatically.

In both cases, the traffic between your machines is encrypted with the WireGuard protocol.

What plain WireGuard asks of you

A WireGuard network is defined by configuration files. Each peer is a public key plus the tunnel addresses it is allowed to use, which the project calls Cryptokey Routing:

[Interface]
PrivateKey = <server-private-key>
Address = 10.8.0.1/24
ListenPort = 51820

[Peer]
PublicKey = <laptop-public-key>
AllowedIPs = 10.8.0.2/32

For a hub with a few clients this is short and transparent, and nothing runs besides the interface itself. Our WireGuard on Contabo guide covers that setup end to end, and wg-easy adds a web interface on top without changing the model.

The cost appears when the network grows in a specific direction:

  • Every device added means editing at least two files. The new peer needs the server, the server needs the new peer.
  • A full mesh multiplies that. If 10 devices must each reach the 9 others directly, that is 45 pairs to describe, on both sides.
  • Someone must be reachable. A tunnel is established toward an endpoint, an IP address and UDP port. Two devices that both sit behind NAT have no such endpoint for each other, which is the situation described in our WireGuard behind CGNAT guide. The usual answer is to send everything through the server.
  • Names and access rules are yours to build. WireGuard gives you addresses. DNS and firewalling between peers are separate work.

None of this is a flaw. It is the scope the project chose, and for a single server it is an advantage: fewer moving parts, one UDP port.

What Headscale adds

With Headscale, the per-device work shrinks to one command. On the server you create a user and a pre-authenticated key:

headscale users create <USER>
headscale preauthkeys create --user <USER_ID>

and on each device, with the Tailscale client installed:

tailscale up --login-server <YOUR_HEADSCALE_URL> --authkey <YOUR_AUTH_KEY>

The device then receives its address and its peers from your server. The feature list in the Headscale documentation includes:

  • MagicDNS and split DNS, so machines have names instead of addresses.
  • ACLs in a central policy file, instead of firewall rules on each host.
  • Subnet routers and exit nodes, to reach a whole LAN or to send all traffic through one node.
  • An embedded DERP server. The documentation describes DERP as a relay mainly used when a direct connection between two nodes cannot be established. It is disabled by default.
  • Registration through OpenID Connect, in addition to pre-authenticated keys.
Rear panels of two stacked rack servers seen head-on: perforated metal grilles, a serial port on a green label, a blue VGA port, one RJ45 Ethernet socket and two stacked module slots on each, with a blurred orange cable crossing the bottom left corner
The rear panels of two rack servers, each with a serial port, a VGA port and an Ethernet socket. Whichever option you pick, one machine with a public address has to be reachable by all the others.

What Headscale's documentation says it is not

This is the part comparisons tend to skip, and it is written plainly by the project itself.

  • Scope. The README states that Headscale "implements a narrow scope, a single Tailscale network (tailnet), suitable for a personal use, or a small open-source organisation".
  • Scale. The FAQ says "Headscale is not enterprise software" and that performance is not a focus. It estimates that the server "can likely handle 100s of devices (maybe more)" when little changes in the network.
  • Missing features. Funnel, Serve and network flow logs are unchecked in the feature list.
  • Deployment. The README says the maintainers "do not support nor encourage the use of reverse proxies and container to run Headscale". Official support covers the binaries and DEB packages. Container images are built for convenience.
  • Clients. Devices use the Tailscale client. The project aims to support the last 10 releases of it, on Linux, OpenBSD, FreeBSD, Windows, Android, macOS, iOS and tvOS.
  • Database. SQLite is recommended. PostgreSQL is still supported but described as being in "maintenance mode".

Headscale is released under the BSD-3-Clause license. The latest release on GitHub when this page was written is v0.29.4, published on 23 September 2026.

What each one needs on the server

Plain WireGuardHeadscale
RoleTunnel between peers you configureControl server for Tailscale clients
Server processA network interface, no daemonA service with a database (SQLite recommended)
Public portsOne UDP port of your choiceTCP 443 (HTTPS); UDP 3478 if embedded DERP is enabled; TCP 80 only if the built-in Let's Encrypt client uses the HTTP-01 challenge
Domain and TLSNot neededHTTPS on port 443 is strongly recommended by the documentation
Client softwareWireGuard on every deviceTailscale client on every device
Adding a deviceEdit configuration on both endsOne tailscale up command
Device to device across NATThrough your server, unless one side has a reachable endpointDirect when possible, relayed through DERP otherwise
Names and access rulesBuilt separatelyMagicDNS and ACLs included

Sources: wireguard.com, the Headscale README and the Headscale documentation (requirements, features, FAQ, DERP), read on 8 October 2026.

Both need the same thing underneath: a small Linux machine with a public IP address that stays online. Neither project publishes a minimum of RAM or CPU on the pages cited here, and an entry-level VPS is the usual home for either.

See the current Contabo Cloud VPS plans

Which one should you run?

Your situationPick
One VPS, a few devices, all traffic goes through the serverWireGuard
You want the fewest moving parts and a single UDP portWireGuard
A router or appliance that only offers a WireGuard clientWireGuard
Laptops, phones and servers that must reach each other directlyHeadscale
Several devices behind NAT or CGNAT on both sidesHeadscale
You add and remove devices oftenHeadscale
You want names and central access rulesHeadscale
Hundreds of frequently changing devices, or a need for vendor supportNeither: look at the hosted Tailscale service

If the last row is closer to your case, Tailscale vs Headscale compares the hosted service and the self-hosted server, and Tailscale vs self-hosted WireGuard covers the same question from the WireGuard side.

Can you run both?

Yes, and it is a reasonable setup. A plain WireGuard interface on its own UDP port and a Headscale service on TCP 443 do not compete for the same port. A common split is a WireGuard tunnel for a fixed link, such as the site-to-site connection between two networks, and Headscale for the personal devices that move around. The price is two systems to keep updated, so do it only if each one solves a problem the other does not.

Summary

WireGuard is a protocol and leaves key distribution to you. Headscale is one way to do that distribution yourself, with the Tailscale client, on a server you control. Start with plain WireGuard when a single hub is enough. Move to Headscale when the configuration files become the main thing you maintain, and read its documentation first: it is explicit about being built for personal networks and small groups. The step-by-step install is in our Headscale control plane guide.

★ Nuremberg GDPR datacenter · ✓ Dedicated IPv4 included · 200 Mbit/s port

Self-host your VPN on your own VPS → ContaboFull root access · public IPv4 · pick your region→

Frequently asked questions

Is Headscale built on WireGuard?
Yes, indirectly. Headscale is a self-hosted implementation of the Tailscale control server, and its README describes Tailscale as a VPN built on top of WireGuard. The packets between your devices are WireGuard packets; Headscale only tells each Tailscale client which keys, addresses and routes to use.
Can I use Headscale with the standard WireGuard client?
No. Headscale speaks the Tailscale control protocol, so devices join with the Tailscale client pointed at your server through the login-server option. A standard wg0 interface configured with wg or wg-quick cannot register with Headscale.
Does Headscale need a server with a public IP?
Yes. The Headscale requirements page asks for a server with a public IP address, served over HTTPS on port 443, on a reasonably modern Linux or BSD system. If you enable the embedded DERP relay, UDP port 3478 must also be exposed for STUN.
How many devices can Headscale handle?
The Headscale FAQ answers with 'It depends' and says the project is not enterprise software: its focus is homelabbers and self-hosters. It states that Headscale can likely handle hundreds of devices when the network changes little, and that many nodes changing often is the case where it starts to struggle.
Which is simpler for two or three devices?
Plain WireGuard. One server, two or three peer blocks and a single UDP port are less to run than a control server with a database, a domain and a TLS certificate. Headscale starts to pay for itself when the number of devices, or the number of pairs that must talk directly, makes hand-written configuration error-prone.