WireGuard in brief: why this protocol is different from what you know
If you have read anything about VPNs in recent years, you will have come across WireGuard. Usually with the word ‘fast’ next to it and little further explanation. This article explains why it is different, and what it is not designed to do.
The age difference
Start at the beginning. The protocols most business VPNs use are old.
IKEv2, the basis of most IPsec setups, was defined in a standard published in December 2005. OpenVPN dates from around the same period. That is not a problem in itself - old software can be excellent - but it does mean they were designed for an internet that looked different.
WireGuard came much later and was incorporated into the Linux kernel in March 2020, in version 5.6. That is not a minor detail: inclusion in the kernel means it runs where network traffic is processed anyway, without packets first having to travel to a program outside the kernel and back again.
The size of the codebase
The most frequently quoted fact about WireGuard is its size: around four thousand lines of code, compared with hundreds of thousands for a complete IPsec or OpenVPN implementation.
That sounds like trivia, but it has a practical consequence. Less code means fewer places for a bug to hide, and it means a security researcher can read through the entire codebase. That is not realistic with hundreds of thousands of lines.
Security you can read for yourself is a different kind of promise from security you have to take on trust.
No choices
This is the most technically interesting point.
IPsec and OpenVPN give you choices. Which encryption algorithm, which key length, which key exchange method, which hash function. This is intended to provide flexibility, but in practice it is a major source of problems: both ends have to agree on the combination they use, and an incorrect setting can produce a connection that works but is weaker than you think.
WireGuard gives you no choice. There is one fixed set of algorithms. If something ever needs replacing, there will be a new version of the protocol - rather than a setting everyone has to change themselves.
Specifically, WireGuard uses Curve25519 for key exchange, ChaCha20-Poly1305 for encryption and authentication, and BLAKE2s for hashing. The handshake is based on the Noise framework and consists of one message in each direction - where IKEv2 needs several.What that means when you use it
You notice three things in practice.
Connecting is fast. The handshake takes one round trip. A laptop waking from sleep has its connection back before you have unlocked the screen.
Switching networks just works. WireGuard has no session in the traditional sense. A peer is recognised by its key, not its IP address. Switch from Wi-Fi to 4G and your traffic comes from a different address - WireGuard follows it, provided the packets are correctly authenticated. You do not notice.
A peer stays silent towards anyone it does not know. If a packet arrives that is not correctly authenticated, there is no reply. No error message, no response. To a port scanner, the device appears not to be there.
What it is not for
Now for the part you do not read in most articles.
WireGuard is a protocol, not a product. It establishes an encrypted tunnel between two endpoints whose keys are already known to each other. How those keys are exchanged, who is allowed to establish which tunnel, what happens when someone leaves the company, how you see who can access what - WireGuard does none of that. This is precisely the layer that products such as Tailscale, NetBird and Safenet add.
It does not have FIPS certification, and its algorithm choices do not meet those requirements. If you work in an environment where this is mandatory - certain US government contracts, for example - WireGuard is not an option for you, however good it may otherwise be.
Speed claims are often exaggerated. WireGuard’s lower overhead compared with IPsec is real and measurable. The performance multiples quoted depend heavily on the hardware and exactly what is being measured. We prefer not to use those figures, because your results may differ.
In summary
WireGuard is smaller, newer and more tightly designed than what most businesses run today. It is not a miracle solution, and it does not solve your access management. But as a foundation to build on, there is currently nothing better - which is why almost everyone building something new in this category starts with it.