Wake-on-LAN Magic Packet Generator

Generate a Wake-on-LAN (WOL) magic packet from any MAC address. View the full 102-byte hex dump, copy the payload, and learn how to set up WOL on your network — all processed locally in your browser.

Wake-on-LAN Magic Packet Generator
Figure 1 — Wake-on-LAN Magic Packet Generator

What Is Wake-on-LAN?

Wake-on-LAN (WOL) is a networking standard that allows a computer to be turned on remotely by sending a special network message called a "magic packet." It was originally created by AMD and Hewlett-Packard in 1995 and has become a standard feature in most modern network adapters and routers.

WOL works at Layer 2 of the OSI model, meaning the target device must be on the same local network segment — or the router must be configured to forward broadcast packets. The feature is invaluable for remote administration, energy management, and scheduled tasks on servers that you access through your router admin panel.

How the Magic Packet Works

A WOL magic packet has a specific structure that the target network adapter's hardware recognizes even when the computer is powered off (but connected to power and network):

SectionBytesContentPurpose
Synchronization Stream6FF FF FF FF FF FFHeader identifying magic packet
Target MAC (repeated 16×)96MAC address × 16Ensures correct target identification
SecureOn Password (optional)0, 4, or 6Shared secretAdditional authentication layer

The total packet is typically 102 bytes (or up to 108 with a SecureOn password). The 16 repetitions of the MAC address provide redundancy — the NIC checks all 16 copies against its own address before triggering the wake event.

How to Enable Wake-on-LAN

WOL requires configuration at multiple levels. Here's a checklist for setting it up:

Step 1: BIOS/UEFI Settings

Enter your computer's BIOS (usually by pressing DEL or F2 during boot) and enable the WOL option. It may be labeled:

  • Wake on LAN
  • Wake on PCI/PCIE
  • Power On by PCI-E
  • Resume by LAN

Step 2: Operating System Configuration

Windows

:: Open Device Manager → Network Adapters → Properties → Advanced
:: Enable: Wake on Magic Packet = Enabled
:: Power Management tab: Allow this device to wake the computer = Checked

:: Disable fast startup (important!):
powercfg /h off

Linux

# Install ethtool if needed
sudo apt install ethtool

# Check WOL support
sudo ethtool eth0 | grep Wake-on

# Enable WOL (g = magic packet)
sudo ethtool -s eth0 wol g

Step 3: Router Configuration

If you need to send WOL packets across subnets, configure your router to forward UDP broadcast packets. Log in to your router at 192.168.1.1 or 10.0.0.1 and check for a "directed broadcast" or "subnet broadcast forwarding" option. See our router IP finder guide if you're unsure of your gateway address.

Pro Tip: For WOL to work over the internet (Wake-on-WAN), you'll need to set up port forwarding on UDP port 9 (or 7) directed to the broadcast address of your subnet (e.g., 192.168.1.255). This is tricky because most routers don't allow forwarding to broadcast addresses — consider using a VPN or an always-on device like a Raspberry Pi as a relay instead.

WOL Transport Protocols

Magic packets can be sent over several transport protocols. The delivery method depends on whether the target is on the local network or remote:

MethodPortScopeNotes
UDP Broadcast9 (discard)Local subnetMost common method, broadcast to 255.255.255.255
UDP Broadcast7 (echo)Local subnetAlternative port, same mechanism
UDP Subnet-Directed9Cross-subnetRequires router directed broadcast support
Raw Ethernet FrameN/ASame L2 segmentUses EtherType 0x0842

Sending WOL Packets from Command Line

Once you've generated your magic packet, you can send it using various tools. You don't need our tool to generate the hex — these utilities build the packet internally — but understanding the packet structure helps with network debugging:

Linux (etherwake / wakeonlan)

# Using etherwake
sudo etherwake AA:BB:CC:DD:EE:FF

# Using wakeonlan
wakeonlan AA:BB:CC:DD:EE:FF

# Specify interface and broadcast address
wakeonlan -i 192.168.1.255 AA:BB:CC:DD:EE:FF

Windows (PowerShell)

# Simple PowerShell WOL script
$mac = "AA:BB:CC:DD:EE:FF"
$macBytes = [byte[]]($mac -split '[:-]' | ForEach-Object { [Convert]::ToByte($_, 16) })
$magicPacket = [byte[]](,0xFF * 6) + ($macBytes * 16)
$udpClient = New-Object System.Net.Sockets.UdpClient
$udpClient.Connect(([System.Net.IPAddress]::Broadcast), 9)
$udpClient.Send($magicPacket, $magicPacket.Length)
$udpClient.Close()
Note: WOL only works when the target device is connected to power and has a wired Ethernet connection (or supports Wake-on-Wireless-LAN, which is less reliable). The network adapter must remain powered in standby mode — this is controlled by the BIOS/UEFI settings. WiFi-based WOL is supported on some newer adapters but requires the access point to buffer the magic packet. For reliable results, always use a wired connection through a router or managed switch.

WOL Security Considerations

Wake-on-LAN has some security implications you should be aware of:

  • No authentication by default — Anyone on the local network can send a magic packet. Use SecureOn passwords where supported.
  • Denial of service — Repeatedly waking a machine can be disruptive. Limit WOL forwarding with firewall rules.
  • Network exposure — Forwarding WOL over the internet (port 9 UDP) opens an attack surface. Use VPN instead.
  • Physical security — WOL can boot an unattended machine. Ensure disk encryption (BitLocker, LUKS) is enabled.

Always keep your router firmware updated and consider enabling MAC address filtering as an additional layer of control on your network.

Key Takeaways
  • A WOL magic packet is 102 bytes: 6 bytes of 0xFF followed by the target MAC repeated 16 times.
  • WOL must be enabled in BIOS/UEFI, the OS network adapter settings, and optionally the router.
  • Wired Ethernet connections are far more reliable for WOL than WiFi.
  • For remote WOL over the internet, use a VPN or relay device rather than port forwarding UDP 9.
  • SecureOn passwords add a basic authentication layer but are transmitted in cleartext.
  • Use our MAC Address Lookup to verify the target device's vendor from its MAC address.

Video: Wake-on-LAN Explained

Related Guides

Frequently Asked Questions

Does Wake-on-LAN work over WiFi?

Some modern network adapters support Wake-on-Wireless-LAN (WoWLAN), but it's less reliable than wired Ethernet. The access point must support buffering magic packets for sleeping clients, and many consumer routers don't implement this correctly. For reliable WOL, always use an Ethernet cable.

What port does WOL use?

Wake-on-LAN typically uses UDP port 9 (discard protocol) or port 7 (echo protocol). The magic packet can technically be sent over any port — the NIC hardware inspects all incoming frames regardless of port. The port matters only for routers and firewalls along the path.

Can I wake a computer on a different subnet?

Yes, but it requires your router to support subnet-directed broadcasts. Configure a static route or port forward to the target subnet's broadcast address. Alternatively, use a relay agent on the target subnet.

Why isn't WOL working on my computer?

Common causes include: WOL disabled in BIOS, Windows Fast Startup enabled (disables NIC standby power), power supply not providing standby power to the NIC, or the magic packet being blocked by a firewall. Check each layer systematically using the setup guide above.

What is a SecureOn password?

SecureOn is an optional extension that appends a 4 or 6-byte password to the magic packet. The NIC only triggers the wake event if the password matches. It provides basic authentication but is sent in cleartext, so it's not a strong security measure.

Can I use WOL to wake my computer from the internet?

Yes, this is called Wake-on-WAN. You need to forward UDP port 9 to your subnet's broadcast address on your router. However, most consumer routers don't support broadcast forwarding. A better approach is to use a VPN to your home network or an always-on device (like a Raspberry Pi) as a WOL relay.

About Tommy N.

Tommy is the founder of RouterHax and a network engineer with 10+ years of experience in home and enterprise networking. He specializes in router configuration, WiFi optimization, and network security. When not writing guides, he's testing the latest mesh WiFi systems and helping readers troubleshoot their home networks.

Promotion for FREE Gifts. Moreover, Free Items here. Disable Ad Blocker to get them all.

Once done, hit any button as below