Usually I would be able to change my wifi mac address with the ifconfig command like :

ifconfig <iface> hw ether XX:XX:XX:XX:XX:XX

Ubuntu have however deprecated ifconfig in behalf of the "ip" command, so I was wondering if there is an way to get similar functionality using that command?

1 Answer 1


First run:

ip link show

This will list your network devices. Find the one you want to change. Next, run:

sudo ip link set dev <your device here> down


sudo ip link set dev <your device here> address <your new mac address>


sudo ip link set dev <your device here> up
  • ip -c a is really handy as a first command, or just ip a which stands for ip address and gives you a slightly different display including IPv4 and IPv6 addresses.
    – pbhj
    Jun 8, 2019 at 10:17
  • 1
    Will this change persist after the reboot?
    – John Smith
    Mar 31, 2022 at 11:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .