How to Change a MAC Address: Windows Settings vs macOS Tools vs Linux Commands

Change a MAC address only when you have a clear reason: privacy on public Wi-Fi, lab testing, or fixing a router rule that is tied to an old adapter. On Windows 10 and 11, Microsoft supports Random hardware addresses for Wi-Fi, which is the cleanest built-in option for many users [source: Microsoft].

TLDR: Use Windows Settings if you want simple Wi-Fi privacy, use macOS Private Wi-Fi Address for per-network privacy, and use Linux commands when you need full control. For example, a technician testing 20 loaner laptops may temporarily set known MAC addresses to check firewall rules faster. In daily use, expect temporary changes to reset after reboot or reconnect unless you configure them to persist. Do not use MAC spoofing to bypass workplace, school, hotel, or paid network controls.

What a MAC address change really does

A MAC address is the hardware address seen by your local network. Your router, access point, switch, or network management tool may log it. Changing it can reduce tracking on public networks, but it does not make you anonymous online. Websites still see your IP address, browser data, cookies, and account logins.

There are two common methods:

  • Randomization: The system creates a private address, usually per Wi-Fi network.
  • Manual spoofing: You set a specific address yourself.

The catch is that some drivers and network tools pretend to support this, then silently ignore the new value. Expect to waste a few extra minutes checking whether the change actually applied.

Windows: easiest through Settings, deeper through Device Manager

On Windows, start with Settings if you only need privacy on Wi-Fi. Go to Settings > Network & Internet > Wi-Fi. Look for Random hardware addresses. You can turn it on for all Wi-Fi networks or only for one saved network.

This is the best option for most people because it is supported by Windows and does not require driver tricks. It is also easier to reverse. Just turn the setting off and reconnect.

For Ethernet or a custom value, use Device Manager:

  1. Right-click Start and open Device Manager.
  2. Expand Network adapters.
  3. Right-click your adapter and choose Properties.
  4. Open the Advanced tab.
  5. Look for Network Address or Locally Administered Address.
  6. Enter a 12-character hexadecimal value, such as 02A1B2C3D4E5.
  7. Disable and re-enable the adapter.

If the option is missing, your driver may not support custom MAC changes. Updating the adapter driver can help, but not always. Honestly, it feels like this should be more consistent across vendors, but it is not.

macOS: use Private Wi-Fi Address first

On modern macOS versions, the practical tool is Private Wi-Fi Address. It gives each Wi-Fi network a different address. Open System Settings > Wi-Fi, click the details button next to a network, and check the private address option. Apple describes this as a privacy feature for reducing tracking across networks [source: Apple].

This method is stable, simple, and safer than forcing a manual address in Terminal. It also avoids breaking normal Wi-Fi behavior.

If you need a temporary manual change for testing, Terminal may work on some Macs and adapters:

ifconfig en0
sudo ifconfig en0 down
sudo ifconfig en0 ether 02:a1:b2:c3:d4:e5
sudo ifconfig en0 up
ifconfig en0

Replace en0 with the real interface name. Use ifconfig to list interfaces. On some systems, macOS will reject the change or reset it after sleep, reboot, or reconnect. That is normal. Apple has tightened network privacy and driver behavior over time.

Linux: best control with commands

Linux gives the most direct control. The basic method uses ip:

ip link show
sudo ip link set dev wlan0 down
sudo ip link set dev wlan0 address 02:a1:b2:c3:d4:e5
sudo ip link set dev wlan0 up
ip link show wlan0

Change wlan0 to your interface name. It may be eth0, wlp2s0, or something else.

If you use NetworkManager, nmcli is often cleaner:

nmcli connection show
nmcli connection modify "WiFi Name" 802-11-wireless.cloned-mac-address random
nmcli connection down "WiFi Name"
nmcli connection up "WiFi Name"

For Ethernet, use:

nmcli connection modify "Wired connection 1" ethernet.cloned-mac-address 02:a1:b2:c3:d4:e5

Some users prefer macchanger:

sudo macchanger -r wlan0
sudo macchanger -s wlan0

It is quick, but your distribution may not install it by default. NetworkManager can also overwrite it unless configured properly.

Which method should you choose?

  • Choose Windows Settings for normal Wi-Fi privacy with the least risk.
  • Choose Windows Device Manager when you need a fixed custom value and the driver supports it.
  • Choose macOS Private Wi-Fi Address for safe per-network privacy.
  • Choose Linux commands for labs, scripting, testing, and repeatable admin work.

Check your work

After changing the address, confirm it locally. On Windows, run ipconfig /all. On macOS or Linux, run ifconfig or ip link show. Then reconnect to the network and check again.

If the network blocks you after the change, switch back. Some routers use MAC filters. Some offices bind access to registered devices. A changed MAC can also trigger captive portals again, which is annoying when all you wanted was a quick test.

Bottom line: use built-in privacy settings when possible. Use manual spoofing only when you understand the network you are working on. Keep a record of the original address before you change anything.