Flamingo Raises $4.5M Seed Round

Skip to content

Wake-on-LAN: how to set it up and why it fails across subnets

Technology
IT Operations
Troubleshooting
Aliaska VarievaAliaska Varieva
September 30, 2026
814 views
Wake-on-LAN: how to set it up and why it fails across subnets

How Wake-on-LAN works, how to set it up on Windows (firmware, adapter driver and advanced settings, power state), which port to use, why it stops working after a Fast Startup shutdown, and how to get the magic packet across subnets for after-hours patching.


Updated: November 2026

Patch night is scheduled, the updates are staged, and half the fleet is switched off. The PCs that are asleep can be woken over the network, and the ones that were shut down usually can't. Here's how Wake-on-LAN works, how to set it up on Windows machines, and why it falls apart the moment the packet has to cross a router.

What is Wake-on-LAN?

Wake-on-LAN (WoL) turns on a computer from a low-power state when its network card sees one specific packet. The card stays partly powered while the PC sleeps. It ignores ordinary traffic and waits for its cue.

That cue is the magic packet. Microsoft's documentation describes it plainly: a broadcast frame with 6 bytes of FF, followed by the target's 48-bit MAC address repeated sixteen times, 102 bytes in total. No IP address inside, no password, no port the PC listens on. The card matches its own MAC and signals the motherboard to power up.

Wake tools usually wrap that payload in a UDP broadcast to port 9, sometimes port 7. The port doesn't matter to the network card, since it reads the frame, not a socket. It matters to your firewall rules and to anything that relays the packet between networks.

Two consequences follow from the design. You need the MAC address of the exact adapter you want to wake, not the Wi-Fi card or the dock. And because the packet is a broadcast, it only travels as far as the local network segment unless you do something about it.

Which port does Wake-on-LAN use?

Wake-on-LAN has no fixed port. The network card scans the frame for the magic packet pattern and ignores the rest, so the packet can ride on any UDP port, or go straight over Ethernet with EtherType 0x0842 and no IP header at all.

Wake tools default to UDP port 9, port 7 or port 0. Port 9 is the default in Configuration Manager and in the Linux wakeonlan tool. Both 9 and 7 are old debugging services: RFC 863 defines port 9 as Discard, which throws away whatever arrives, and RFC 862 defines port 7 as Echo.

Pick one port and use it in the wake tool, in the firewalls between the sender and the target subnet, and in any router rule that relays it. The sleeping PC needs no firewall rule of its own, since its card reads the packet before Windows is awake to apply one. If routers relay subnet-directed broadcasts, Microsoft's Configuration Manager guidance is to use a non-default port and accept it only from the site server.

How to set up Wake-on-LAN on Windows

Three layers have to agree before a PC will wake: the firmware, the network adapter driver, and Windows power settings. Miss one and the packet arrives at a card that isn't listening.

Firmware. Enable the wake option in the BIOS or UEFI setup. Vendors name it differently: Wake on LAN, Remote Wake Up, Power On by PCI-E, Resume by LAN. Look for deep-sleep or energy-saving modes too, since some cut power to the network card completely when the PC is off. If you're already in those menus for other work, our guide to BIOS settings covers how to find them on the main vendors' boards.

Adapter driver. In Device Manager, open the network adapter's properties. On the Power Management tab, tick "Allow this device to wake the computer" and "Only allow a magic packet to wake the computer". The second box stops random network chatter from waking machines at 3 a.m. On the Advanced tab, set Wake on Magic Packet to Enabled if the driver exposes it.

Scripted. On a fleet, clicking through Device Manager doesn't scale. PowerShell covers the driver side:

powershell
Get-NetAdapterPowerManagement -Name "Ethernet"
Set-NetAdapterPowerManagement -Name "Ethernet" -WakeOnMagicPacket Enabled
powercfg /devicequery wake_armed

The last line lists every device currently allowed to wake the machine. If the Ethernet adapter isn't in that list, the PC won't wake from the network.

Network adapter settings that control wake

The names on the Advanced tab come from the driver, so they differ between vendors. Behind each wake setting sits a standard registry keyword that Microsoft defines, and the keyword is the same on every card that supports it.

Advanced tab settingKeywordWhat it doesSet it to
Wake on magic packet*WakeOnMagicPacketWakes the PC when a magic packet with its MAC arrivesEnabled
Wake on pattern match*WakeOnPatternWakes the PC when a packet matches a wake pattern Windows setDisabled for magic-packet-only wake
Wake on magic packet when system is in the S0ix power state*ModernStandbyWoLMagicPacketLets a magic packet wake a laptop in Modern StandbyEnabled on laptops you wake from standby
ARP offload*PMARPOffloadThe card answers IPv4 ARP requests while the PC sleepsEnabled
NS offload*PMNSOffloadThe card answers IPv6 neighbor solicitations while the PC sleepsEnabled

Microsoft's definitions turn magic packet wake and pattern wake on by default. Pattern wake lets ordinary traffic wake the machine, so turning it off does the same job as the "Only allow a magic packet" box above. The S0ix setting is off by default, needs Windows 10 version 1607 or later, and covers Modern Standby only, not hibernate.

Leave both offloads on. Microsoft's NDIS documentation explains that routine ARP requests would otherwise wake a sleeping host and waste power, so the card answers them and the PC stays asleep until a real wake request arrives. Intel's Wi-Fi drivers list the same settings as ARP offloading for WoWLAN and NS offloading for WoWLAN, next to GTK rekeying for WoWLAN, and those only affect Wake on Wireless LAN.

To read and change them by keyword:

powershell
Get-NetAdapterAdvancedProperty -Name "Ethernet" |
  Where-Object RegistryKeyword -match 'Wake|WoL|Offload' |
  Format-Table DisplayName, DisplayValue, RegistryKeyword
Set-NetAdapterAdvancedProperty -Name "Ethernet" -RegistryKeyword "*WakeOnPattern" -RegistryValue 0

A setting missing from that list isn't supported by the driver.

How to send a magic packet to test it

Test each PC model before patch night. Put the machine to sleep, then send a packet from another computer on the same subnet. On Windows, PowerShell can build and send it with no extra tools:

powershell
$mac = "00-1A-2B-3C-4D-5E"
$macBytes = $mac -split '[:-]' | ForEach-Object { [Convert]::ToByte($_, 16) }
[byte[]]$packet = (,[byte]0xFF * 6) + ($macBytes * 16)
$udp = New-Object System.Net.Sockets.UdpClient
$udp.EnableBroadcast = $true
$target = [System.Net.IPEndPoint]::new([System.Net.IPAddress]::Broadcast, 9)
[void]$udp.Send($packet, $packet.Length, $target)
$udp.Close()

To reach another subnet, swap the broadcast address for that subnet's, such as [System.Net.IPAddress]::Parse("10.20.30.255"), once the router allows directed broadcasts. On Linux, wakeonlan sends the same UDP packet to port 9, and etherwake sends it as a raw Ethernet frame, which needs root. After the machine wakes, powercfg /lastwake on it should name the network adapter as the wake source.

Why Wake-on-LAN stops working after shutdown

This is the failure that shows up on patch night. The settings are right, the PC wakes fine from sleep, and after a normal shutdown it stays dark.

Microsoft documents the reason. The default shutdown in Windows 10 is hybrid shutdown, also called Fast Startup, which puts the machine into S4. Microsoft's Wake on LAN article says WoL from S4 or S5 is unsupported in that case and that network adapters "are explicitly not armed" for it. WoL is supported from sleep (S3) and from hibernate when a user explicitly chooses it. Windows 11 keeps Fast Startup on by default, so the same rule applies there.

There's a footnote in the same article. Some firmware can arm the network card for wake from S4 or S5 without Windows being involved. That's why WoL after shutdown works on some models and fails on others in the same office.

You have three options for machines that need to wake after hours:

  1. Leave them asleep, not shut down. Sleep is the state Windows supports for WoL.
  2. Turn off Fast Startup on those machines, which Microsoft doesn't recommend in general but which lets supported firmware wake from a full shutdown. Our Fast Startup guide covers turning it off across a fleet.
  3. Rely on firmware. Test per model.

Laptops with Modern Standby add their own rules. They idle in a low-power S0 state instead of classic sleep, and Microsoft notes that USB-attached wired adapters can lose wake capability during standby. On Windows 11 24H2, Modern Standby also disables most wake sources when it detects excessive battery drain.

Model-specific failures are common enough to have their own threads. This one tracks WoL failing on newer Dell OptiPlex models with Intel I219-LM adapters:

Powering on vPro PCs with Intel AMT

Every vPro-enabled PC includes Intel Active Management Technology (AMT), which has its own out-of-band power control that works below Windows. Once a machine is provisioned, a management console such as Intel Endpoint Management Assistant can power it on with no magic packet, or set an alarm clock that starts it at a scheduled time before the patch window. Provisioning also sets which power states AMT stays active in, so check that setting on each model before you count on it. AMT needs that provisioning step and a management server, so it fits fleets that already run vPro hardware.

Why Wake-on-LAN fails across subnets

The magic packet is a broadcast. Routers don't forward broadcasts, so a packet sent from the admin VLAN never reaches the finance VLAN. WoL works on the bench and fails in production, where every floor has its own subnet. Our VLAN guide covers why broadcasts stop at that boundary.

There are three ways around it.

Subnet-directed broadcast. Send the packet to the target subnet's broadcast address, for example 10.20.30.255. The routers carry it like a normal packet until the last router turns it into a local broadcast. That last hop only happens if you enable directed broadcasts on the router interface. It's off by default for a reason: RFC 2644 (August 1999) made "disabled" the required default after Smurf attacks used directed broadcasts to amplify floods. If you turn it on, do it on internal interfaces only and restrict which source can send.

A relay on the router. Many routers and layer 3 switches can forward a specific UDP port to a subnet's broadcast address. It's the same mechanism with a narrower rule, because only port 9 from your management host gets through.

A sender inside each subnet. Put the wake job on a machine that's already on the target network, such as an always-on server or another managed PC. The packet never crosses a router, so no router changes are needed. Configuration Manager has worked this way since version 1810: it finds a client that's awake on the target subnet and has that client send the magic packet. Microsoft lists 802.1X network authentication as a limitation of that feature, which matters on wired networks with port authentication.

In Configuration Manager, the Allow network wake-up client setting arms the network adapter on each client, so you don't script the driver side separately, and the Wake On LAN port number (UDP) client setting sets the port for both its older and newer wake methods. Since Configuration Manager version 2010, the site can also wake clients at a deployment deadline through an online peer in the same subnet.

If your RMM or remote access tool has a wake action, check where it sends the packet from. When it asks an online agent in the target subnet to send it, as Configuration Manager does, each site needs one machine that stays on through the patch window.

One thing not to do: forward the WoL port from the internet to the LAN. If someone needs to wake a machine remotely, they connect to the VPN first and send the packet from inside. Our post on port forwarding covers why an open inbound port is the wrong tool here.

This r/sysadmin thread describes the harder version of the problem: clients spread across several sites and networks, with 802.1X in place.

Wi-Fi, docks and laptops

Wake-on-LAN was built for wired networks. Wi-Fi has a variant, Wake on Wireless LAN, but the adapter has to stay associated with the access point while the PC sleeps, and that support varies widely by card and driver. Plan patch windows around wired machines and treat Wi-Fi wake as a bonus.

Docks cause their own confusion. A laptop on a USB-C dock uses the dock's network adapter, and some docks pass the laptop's own MAC address through instead of their own. Your wake tool needs the MAC that's on the wire at that desk. Check it on the machine with Get-NetAdapter while it's docked, not from an old inventory export.

Surface devices have their own documented rules. Microsoft says they wake from Modern Standby while on AC power and connected to a wired network through a Surface Ethernet adapter or Surface dock, by default on Windows 10 version 1607 or later, with a registry change needed on Surface Studio 2. Waking from hibernate or shutdown depends on the dock, and Microsoft covers Surface Dock 2 and the Surface Thunderbolt 4 Dock in separate guides.

Using Wake-on-LAN for after-hours patching

Patching at night only works if the machines are on at night. WoL closes that gap without asking staff to leave PCs running.

A workable routine looks like this. Keep an inventory of wired MAC addresses per site. Wake machines in batches, not all at once, so the network and the update source don't get hammered. Give each machine time to boot and check in, then run the patch job, confirm the reboot, and let it return to sleep. The next morning, powercfg /lastwake on a sample of machines shows what woke them.

The machines that didn't wake are the useful output. Chase them by model, starting with firmware and Fast Startup before you look at the network. Our patch management roundup compares tools that schedule this kind of window. With OpenFrame, our open, AI-native infrastructure for IT and security, you can run the Get-NetAdapterPowerManagement check as a script across your devices and collect the output, so the unarmed machines show up before patch night instead of after it.

TroubleChute's walkthrough covers the Windows side step by step, including the network adapter settings:

Wake-on-LAN troubleshooting checklist

When a machine won't wake, work from the cable up:

  1. Right MAC. Confirm the MAC belongs to the wired adapter in use, not Wi-Fi or an old dock.
  2. Link light. With the PC off or asleep, the port's link light should stay on. Dark means the card has no power, so check firmware deep-sleep settings.
  3. Firmware. The wake option is enabled in BIOS or UEFI, and it survived the last firmware update.
  4. Driver. powercfg /devicequery wake_armed lists the adapter, and magic packet wake is enabled.
  5. Power state. Test from sleep first. If sleep works and shutdown doesn't, it's Fast Startup or firmware.
  6. Packet delivery. Capture on another machine in the same subnet and filter for UDP port 9. No packet means the problem is routing, not the PC.

The short version

Wake-on-LAN wakes a PC when its network card sees a magic packet with its MAC address. It works reliably from sleep, unreliably after a Fast Startup shutdown, and not at all across routers until you add a directed broadcast, a relay, or a sender inside each subnet. Set the firmware, driver and power state together, test per model, and keep the wake traffic inside your network.

Aliaska Varieva

Aliaska Varieva

VP of Engineering

Hi! I’m Aliaska, and I’ve been working as a software engineer (mostly Java + a bit Kotlin) for over 8 years now. I mostly spend my time building backend services, integrating systems, fixing bugs (the fun part 🙃), and making sure things don’t fall apart behind the scenes.

Related Content

Frequently Asked Questions

/blog/wake-on-lan

Still deciding?

Ask Mingo answers from our docs and customer stories.

Loading related content and questions