VPN Kill Switch: What It Is and How It Works
On this page
Summary: A VPN kill switch is designed to block internet traffic from leaving your device outside the VPN tunnel if the connection fails, helping prevent apps from falling back to your regular connection and exposing your real IP address. It is a failure-control feature, not an encryption feature, and its coverage varies: depending on the provider, platform, and setting, it may block the whole device or only selected apps, may stop protecting you once you disconnect manually, and may not catch traffic the operating system exempts or reroutes, depending on how blocking is enforced.
VPN Advisors is an independent, affiliate-supported website that explains how VPNs work, what they protect, and how to evaluate VPN services. This article explains how a VPN kill switch works, when it blocks traffic, and why its protection can vary between apps and operating systems. For a broader look at VPN security features and their limitations, see our VPN Protection Features guide.
What problem a kill switch solves
When a VPN is connected, the VPN client tells your operating system to send traffic to a virtual network interface, where the client encrypts it and forwards it to the VPN server. If that tunnel stops working, whether because your Wi-Fi changed, the server restarted, the device woke from sleep, or the app hit an error, traffic can fall back to another available route unless blocking rules prevent it. That route is often your ordinary connection. Mullvad’s published security documentation calls this failing open and describes the goal of its leak protection as failing closed instead: if packets cannot leave encrypted the way the VPN intends, they should not leave at all.
That framing is the clearest way to separate a kill switch from the rest of the VPN:
- The tunnel and its encryption protect traffic that travels through the VPN.
- Routing decides which traffic is sent to the tunnel in the first place.
- The kill switch decides what happens to traffic that would otherwise leave by another path.
A kill switch does not strengthen the encryption of traffic already inside a working VPN tunnel. Its value is concentrated in the moments when the tunnel is down, changing, not yet up, or being bypassed by a route that its blocking rules can catch.
What “blocked” still allows
No working kill switch blocks literally everything, because the VPN needs some traffic in order to reconnect. Mullvad’s documentation is unusually explicit about its exceptions: loopback traffic, DHCP so the device can keep its local IP address, a narrow subset of IPv6 neighbor discovery, traffic to the specific VPN server being connected to (limited to the VPN’s own process where the platform allows it), optional local network access, and the app’s own API traffic. Leviathan Security’s TunnelVision research makes the same point in general terms: full-tunnel VPNs keep exceptions for the VPN server’s address and for DHCP. These exceptions are deliberate, so “blocks all traffic” needs to be read alongside the product’s documented exceptions.
How a kill switch behaves as the connection changes
The most useful way to understand a kill switch is to follow a connection through its states. The table below is based on what two providers document for their two kill-switch modes: Proton VPN’s standard and Advanced kill switches, and Mullvad’s always-on leak protection and its Lockdown mode (also labeled “Always require VPN”). Other implementations can behave differently at any of these points. The comparison assumes full-tunnel traffic, not apps deliberately excluded through split tunneling.
| Connection state | Session-scoped kill switch | Persistent mode (no VPN, no internet) |
|---|---|---|
| Connected and working | Traffic flows through the tunnel | Same |
| Tunnel drops unexpectedly | Internet traffic is blocked except for necessary control and reconnection traffic | Same |
| Changing servers or reconnecting after sleep | Blocked until the new tunnel is up (Mullvad documents this explicitly) | Same |
| You click Disconnect | Blocking ends; traffic uses your regular connection | Covered internet traffic stays blocked until you connect again |
| Device starts up or shuts down | Proton’s standard kill switch is not active; Mullvad may keep blocking if auto-connect is enabled | Both providers aim to block, though Mullvad says some leaks may still occur during macOS startup |
The practical split is between a kill switch that protects a VPN session you started and a mode that treats “no VPN” as “no internet.” Mullvad’s documentation stresses that its “Always require VPN” setting is regularly mistaken for the kill switch: the setting only changes whether the deliberately disconnected state allows traffic, while protection during drops and server changes is always on and cannot be turned off. Proton presents the same split as two named options and notes that the standard kill switch suits people who sometimes want to use the internet without the VPN. Mullvad also notes that desktop apps excluded through split tunneling can still use the internet in Lockdown mode.
How kill switches are enforced
Behind the toggle, a kill switch is usually implemented in one of three ways, and the method determines what it can and cannot catch.
Firewall rules on desktop operating systems
On Windows, macOS, and Linux, VPN apps can write rules into the operating system’s packet filter. Mullvad uses the Windows Filtering Platform (WFP) on Windows, PF on macOS, and nftables on Linux, and applies rule changes as atomic transactions so there is no gap between one rule set and the next. Proton says its Windows kill switches also use WFP, while its advanced Linux mode redirects outgoing traffic to a dummy network interface.
The official WireGuard client for Windows shows how closely a kill switch can be tied to configuration. According to its technical notes, when a tunnel has a single peer whose Allowed IPs include a /0 route, the client adds firewall rules that block traffic outside the tunnel and restrict DNS to the configured servers. Splitting the same address space into two /1 routes produces nearly identical routing without those rules. The client’s “Block untunneled traffic (kill-switch)” checkbox switches between the two.
A second design difference sits underneath the label. Some kill switches react when the app detects that the connection dropped; others keep blocking rules in force for the entire session, whatever the app detects. Mullvad avoids the term “kill switch” for exactly this reason, saying it suggests a red button that has to be pressed when something goes wrong. The difference matters for failures the app never notices, covered below.
Operating system controls on mobile
On Android and iOS, apps cannot directly edit the firewall or routing table, so a kill switch depends on what the operating system exposes. Android offers two system settings: Always-on VPN, which starts a chosen VPN app at boot and keeps it running, and Block connections without VPN, often called lockdown, which stops traffic that does not go through that VPN. Android’s VpnService documentation states that normal networking is restored automatically if a VPN app crashes or is killed by the system, which is why the lockdown setting, rather than the app alone, is what keeps traffic blocked in that situation. Google’s Android Enterprise VPN guidance adds that when lockdown is on, apps excluded from the VPN lose network access instead of using the regular connection.
On iOS and macOS, Apple’s Network Extension framework provides a developer setting called includeAllNetworks. Apple’s documentation says it routes network traffic through the tunnel except traffic for designated system services needed for normal device functionality. Proton described this as the kill switch capability Apple made available to developers in iOS 14.
App-level kill switches
A third design does not block the network at all. NordVPN’s Windows app offers both an Internet Kill Switch, which cuts the device’s internet connection when it is disconnected from the VPN, and an App Kill Switch, which shuts down programs you select when the VPN connection is lost. App-level protection covers only the chosen apps. Everything else on the device, including background services and updaters you did not think to list, can keep using your regular connection.
Same label, different behavior
Provider naming makes kill switches hard to compare, because similar labels describe different scopes. The descriptions below reflect each provider’s or platform’s own documentation, not independent testing.
| Label you may see | Where | Documented behavior |
|---|---|---|
| Kill switch (standard) | Proton VPN | Blocks internet traffic after an unexpected drop while reconnecting; disengages on manual disconnect or shutdown |
| Advanced kill switch | Proton VPN (Windows, Linux GUI; iOS/iPadOS beta) | Blocks internet access at all times unless a VPN connection is active, including after manual disconnect and across restarts |
| Internet Kill Switch / App Kill Switch | NordVPN (Windows) | Device-wide internet block versus closing selected programs |
| Internet Kill Switch / Network Lock | ExpressVPN | Desktop and mobile protection; iOS has Standard and Advanced modes. Router blocking depends on the model and configuration |
| Always-on kill switch / Lockdown mode | Mullvad | Drop protection always active with no setting to disable it; Lockdown mode additionally blocks covered traffic while deliberately disconnected |
| Block untunneled traffic (kill-switch) | WireGuard for Windows | Firewall rules enabled by a /0 default-route configuration |
| Always-on VPN / Block connections without VPN | Android (system settings) | Keeps a chosen VPN running / blocks traffic that does not use it |
| includeAllNetworks | Apple Network Extension (developer setting) | Routes most traffic through the tunnel, with listed system exceptions |
Behavior can also change within a single provider. NordVPN’s help center describes its Linux kill switch as blocking traffic after the connection breaks or after a manual disconnect, while its iOS and App Store macOS apps describe VPN bypass prevention that keeps traffic covered by the VPN configuration inside the tunnel. A kill-switch claim is therefore a claim about one app on one platform, not about the provider as a whole.
Where kill-switch protection stops
Traffic the operating system exempts
Some traffic never reaches the VPN app’s control. In 2022, Mullvad reported that Android sends connectivity checks outside the tunnel every time the device joins a Wi-Fi network, even with Block connections without VPN enabled; its security documentation lists DNS lookups, HTTP(S) connectivity checks, and network-provided time (NTP) as exempt. Mullvad said no VPN app can fix this from inside the app, and reporting at the time said a Google engineer treated the behavior as intended. Mullvad’s current known-issues documentation also describes brief leaks during Android VPN reconfiguration, including cases where lockdown is enabled.
Apple’s includeAllNetworks documentation names its own exceptions: captive-portal negotiation for Wi-Fi hotspots, certain cellular-only services such as VoLTE, and communication with companion devices such as an Apple Watch. Proton reported in 2022 that certain DNS queries from Apple services could still leave outside the VPN even with that capability enabled. In 2024, Mullvad reported that the macOS firewall could disregard rules after some system updates until a reboot, and that Apple’s own apps and services did not respect the routing table in versions from macOS 14.6 until a 15.1 beta, so when the firewall also failed, that traffic could leave outside the tunnel. Proton’s current macOS guidance also warns that changing VPN servers may briefly expose the real IP address even with its kill switch enabled.
Connections that were open before the VPN started
A kill switch is mainly about what happens when a tunnel fails, but the moment a tunnel starts matters too. In 2020, Proton disclosed that iOS 13.3.1 and 13.4 did not close existing connections when a VPN connected, so long-lived connections, such as the one Apple’s push notification service maintains, could continue outside the tunnel for minutes or hours. Proton later said the kill switch capability Apple added in iOS 14 blocks those existing connections when it is enabled.
Failures the kill switch never detects
A reactive kill switch can only respond to failures it can see. Leviathan Security’s TunnelVision research (CVE-2024-3661) showed that an attacker on the same local network can use DHCP option 121 to push routes that send traffic out through the physical network interface instead of the tunnel. Because the VPN’s own connection to its server stays intact, the researchers found that kill switches were never tripped and VPN apps kept reporting a connection in every case they observed. Leaving the VPN tunnel does not automatically expose the contents of HTTPS or other separately encrypted connections.
Leviathan observed some providers mitigating this with firewall rules that drop traffic to non-VPN interfaces, but noted that the mitigation still leaves a side channel an attacker can use to infer where traffic is going. Android was unaffected in the researchers’ tests because its DHCP client did not implement option 121. TunnelVision is the clearest example of why “the VPN shows as connected” and “all traffic is inside the tunnel” are separate claims.
Gaps in timing and app state
- Startup: protection depends on when blocking rules load. Mullvad uses persistent filters on Windows and an early-boot unit on Linux, but says that on macOS it cannot guarantee its service starts before other programs, so some leaks may still occur.
- App or firewall failure: Mullvad says that if its firewall integration fails, there is little the app can do to prevent leaks, and it attributes most such failures on Windows to third-party security software interfering with WFP. On Android, an app crash restores normal networking unless lockdown is on.
- Manual disconnect: a session-scoped kill switch steps aside by design. Only a persistent mode keeps blocking covered traffic after you choose to disconnect.
Exposure while the VPN is connected
A kill switch addresses traffic that leaves outside the tunnel when the tunnel is not carrying it. DNS, IPv6, and WebRTC exposure can occur while the VPN appears fully connected, through different mechanisms, and may need additional protections beyond the kill switch. Some kill-switch implementations restrict part of this as a side effect, such as WireGuard for Windows limiting DNS to configured servers, but that is a property of a specific implementation, not of kill switches as a category.
Reading a kill-switch description
Because the label alone says little, these questions separate one kill switch from another:
- Does it block the whole device, or only selected apps?
- Is it active only during a session you started, or also after a manual disconnect, an app exit, and a reboot?
- Is blocking enforced for the entire session, or triggered only when the app detects a drop?
- Which platforms offer it, and does it behave the same way on each?
- Does it allow local network access, and is that optional?
- What does the operating system exempt on that platform, regardless of the app?
Clear answers tell you what a particular kill switch covers. None of them turns a kill switch into a guarantee that no traffic can ever leave outside the VPN. A normal IP or DNS leak test checks only the state in which it ran; it cannot by itself establish how the kill switch behaves during startup, reconnection, or a route change.