How to Spoof your MAC Address in Mac OS X

A MAC address is a unique identifier assigned to your network card, and some networks implement MAC address filtering as a method of security. Spoofing a MAC address can be desired for multiple reasons, and it is very easy to spoof your MAC address in Mac OS X 10.4, 10.5, 10.6, 10.7, OS X 10.8, and OS X 10.9. For the purpose of this article, we are going to assume you want to spoof your Mac’s wireless MAC address, meaning your wi-fi card. Without further ado, here’s a three step process on how to do just that…

Retrieving your current MAC address

First, you’re going to want your current wireless MAC address so you can set it back without rebooting. Launch the Terminal app and type the following command:

ifconfig en1 | grep ether

You’ll know see something like:

ether 00:12:cb:c6:24:e2

And the values after ‘ether’ makeup your current MAC address. Write this down somewhere so you don’t forget it. If you do, it’s not the end of the world, you’ll just have to reboot to reset it from a change.

Note, it’s possible that your Mac has the wi-fi card on en0, so you may need to adjust the string accordingly.

Spoofing a MAC address

To spoof your MAC address, you simply set that value returned from ifconfig to another hex value in the format of aa:bb:cc:dd:ee:ff. You can generate a random one if need be.

For this example, we will set our wireless MAC address to 00:e2:e3:e4:e5:e6 by issuing the following command:

sudo ifconfig en1 ether 00:e2:e3:e4:e5:e6

The sudo command will require that you enter your root password to make the change.

Again, some Macs use en0, so if you run into any issues you can try that.

Verifying the Spoofed MAC address worked

If you want to check that the spoof worked, type the same command as earlier:

ifconfig en1 | grep ether

Now you will see:

ether 00:e2:e3:e4:e5:e6

Meaning your MAC address is now the value you set it to. If you want to further verify the spoof, simply login to your wireless router and look at the ‘available devices’ (or attached devices) list, and your spoofed MAC address will be part of that list.

If you want to set your MAC address back to its real value, simply issue the above ifconfig commands with the MAC address that you retrieved in step 1. You can also reboot your Mac.

Enjoy!

Note: Reader Dee Brown points out the following, which may help with some users having difficulties: “running 10.5.6 you need to do the trick to disassociate from the network. ****DO NOT TURN AIRPORT OFF****. What you will have to do is click your airport and click join network and enter some bogus name as the network ssid. Then while it’s trying to connect click cancel.At this point you may spoof using the sudo ifconfig en1 ether command”

other readers point out that Dee Brown’s trick works in 10.5.7 and above too. Thanks Dee!

Update: If you’re still having problems with MAC address spoofing in Leopard or Snow Leopard, the above method still works but try disassociating with any wireless network BUT keep your wireless Airport on (as mentioned above) – an easy way to do this is to type the following in the command line:

airport -z

Note that you have to have the ‘airport’ command setup to work for users, you can do that by copy and pasting this command into the Mac Terminal:

For some computers Wi-Fi may be the interface but you spoof by specifying “ether” instead.

sudo ifconfig en0 ether aa:bb:cc:dd:ee:ff

Remember to disassociate from any network beforehand with “airport -z” while keeping the card active. If you continue to have problems or receive a “bad value” message, try turning the wireless NIC off and on again using the following:

sudo ifconfig en0 down

Now re-enable the NIC:

sudo ifconfig en0 up

Then proceed to spoof the MAC address:

sudo ifconfig en0 ether aa:bb:cc:dd:ee:ff

Reenabling the network card may cause it to join the last available wireless network.

Hello,
I did it, but there is a problem – when I verify the new mac address there is nothing done, the MAC address is the original. I’m using OS-X 10.4.11 and external wi-fi card (RTL) and Realtek WLAN Client Utility.

##
# Configure a network interface MAC Address setting
##
#
# This script will set the MAC Address setting for the specified interface(s)
#
# The name of the interface (ex. en0) must be edited to match the interface
# to which the MACADD setting should be applied
#
##

StartService ()
{
ConsoleMessage “Configuring MACADD”

### uncomment lines and change the value following ‘MACADD’ as appropriate mac address

15. Uncomment the /sbin/ifconfig line(s) to set the MACADD for a particular interface.

Note: Removing the number sign (#) from the beginning of a line uncomments it. Typically, en0 is the interface name for the Built-in Ethernet port and en1 is interface name for the AirPort Card. This is not always the case, though. To confirm that a network port is associated with a particular interface name, open the Network Utility (/Applications/Utilities/), and click the Info tab.

16. When you have finished customizing the file, save it (press Control-O), press Return, and exit pico (press Control-X).

When you restart the computer, MACADD is set for the interface that you specified.

Notes

1. The MACADD will be reset after changing a Location, waking the computer from sleep, or changing the state of the network interface. To use the script again without having to restart, enter the following command:

sudo SystemStarter start MACADD

2. If you experience any issues or wish to not set MACADD during startup, you can turn off the new script by changing the MACADD line in /etc/hostconfig to:

Dude, How does that “show how mac address filtering is so weak”? You would have to know the allowed mac addresses in the first place to put it in, and wouldn’t you have to be on the network or physically use the computer to know…

I’m new to Macs, so I could be doing something wrong, but…
Every time I try to do the “sudo ifconfig en1 ether 00:e2:e3:e4:e5:e6” command it doesn’t work. I enter the password correctly, but when I check the mac address after with the “ifconfig en1 | grep ether” command it returns my default mac address.

I am on OSX 10.5.4 so it could be an issue with this release of Leopard. Has anyone else on 10.5.4 gotten it to work?

Spoofing your can be done for various reasons. Any Internet Service Providers can be expecting a specific MAC address prior to providing an IP address. You can using spoofing to provide the expected MAC address.

Where I work, they have a service issue which is caching my old MAC address and it prevents me logging in the next day if they service doesn’t drop my old connection. With a quick spoof of an MAC address, I can connect without waiting on IT to fix their problem.

I’m having trouble spoofing my MAC.
I’ve done the right commands, and my original MAC address keeps coming back, well, the MAC address didn’t change in the first place. I was wondering if anyone else has had this problem, some tips would help. Also, I’m running Mac OS X 10.4.11
Thanks.

running 10.5.6 you need to do the trick to disassociate from the network. ****DO NOT TURN AIRPORT OFF****. What you will have to do is click your airport and click join network and enter some bogus name as the network ssid. Then while it’s trying to connect click cancel.At this point you may spoof using the sudo ifconfig en1 ether command

In Linux (yes, not OS X, but still UNIX style) the interface must be “down” first otherwise it’s considered to be in use and can’t be changed – so try this:
sudo ifconfig en0 down
sudo ifconfig en0 lladdr xx:xx:xx:xx:xx:xx
sudo ifconfig en0 up

Make sure that you are connected to the network interface that you would like to spoof for it to work. i.e. if I wanted to spoof my MAC address on the en1 (airport protocol), I would need to turn wifi on BUT not connect to any network then continue with the terminal process.

Couldn’t make it work with the above instructions on my MBP early 2008 running OS X 10.5.7 (or the previous).
Went out on a limb, bought a USB ethernet dongle (TreneNet TU2-ET100). Thought perhaps I could spoof it, using a different driver.
No luck when I plugged it in, so I downloaded driver from TrendNet.http://www.trendnet.com/products/proddetail.asp?prod=150_TU2-ET100
(Went to downloads, grabbed the universal zip)
No luck with the TRENDnet dongle…
BUT NOW SPOOFING MY INTERNAL ETHERNET (en0) WORKS!
Not sure what happened. It works while the internal interface is up and running!

Just updated to 10.5.8 this arvo and immediately afterward found a hotspot that doesn’t like my machine. Seems the ifconfig command returns fine but the MAC doesn’t change even with the disassociate trick.

If this is apple being bitches again and trying to tell me what I can and can’t do with my hardware I reckon I’m going to call it a day and move to windows 7 next refresh.

Due to a bug in OS X 10.5.6+, the built in mac-address spoofing
function requires the following work around:

To determine your old mac-address:

ifconfig en1 | grep ether

Do not ‘Turn Airport Off’, instead deactivate your wireless card by:

Click ‘Join Other Network…’ and enter a fake SSID. Allow it to
attempt a connection and then go ahead and cancel the request. Your
card is now deactivated allowing us to proceed with the following
command:

Folks! Mac spoofing of ethernet (en0) works on Snow Leopard.
I was able to spoof mac address on en0 (ifconfig en0 ether xx:xx:xx….).
There were some problems with DHCP, I couldn’t get the IP though – I don’t know, maybe it was a problem with my router or something, maybe I have to re-set the dhcp client on macosx. Now, I don’t have time to check further, however, it gives hope that ethernet spoofing works again (people say it worked in Tiger w/o problems).

I used to be able to spoof my MAC address with Leopard on my MacBook Pro either through the terminal, via AppleScript, or with the freeware app ChangeMAC. Now with Snow Leopard (10.6.0), I can change the MAC address, but once I do, I can’t connect to any wireless router. I’ve tried all of the above methods, which worked before, but nothing seems to help…including turning it off/on (for the I.T. Crowd fans).

I sure hope someone can figure this out. MAC spoofing makes my life a lot better.

I am having the same problem as Kevein Edwards. I had been spoofing my MAC address on Leopard (all releases) without any problems using the tutorial command of ‘sudo ifconfig en1 ether XXXXXXXX’.

Having upgraded to Snow Leopard, this command now seems to be broken. When I change my MAC address using the same command, it breaks the wireless. By this I mean that I cannot join ANY networks (all I get are timeout errors). When I go to System Prefs>Network>Airport>Advanced, there is now a line added at the bottom “Airport ID.” Typing the ‘ifconfig en1 | grep ether’ command, it returns the value I entered.

When I change my MAC address back to the one listed, the wireless returns to normal operation. I am guessing that the new release has disallowed spoofing, but I am not sure. I remember that I cannot change my ethernet port (en0) because it supposedly has a hardware lock, but the wireless card never had this issue. It seems that this is too new of an issue to have received attention (found nothing on google). Does anyone have any idea of a way to bypass this new software change?

I changed my mac adrress but now in my router configuration I appear with the old Mac address and with the new one. I’m sure that what i’m looking at is MY MAC and not the router’s mac. So i’m taking 2 ip’s of my range in my wlan like this:
maceze 192.168.1.101 00-e2-e3-e4-e5-e6
maceze 192.168.1.103 00-25-00-47-d7-ef

OK. I am still having the same problems as bluefish. I did it the way the update at the bottom of the instructions sad with using airport -z and all that. From the command line it looks good but the Airport is inoperable.

I hardly believe Appl disabled the feature without disabling the actual command. If the command is there, it should work. I think they didn’t test this and now they are like WTF.

As we all know, Snow Leapord Airport issues are viral on the interwebs. If the above instructions actually work for someones Airport wireless and not for the rest of us, I have hope it will work but I haven’t seen one testimonial of someone who has actually had success changing the MAC address of their Airport wireless with Snow Leopard. Major bug IMO.

Once I do achieve success, I will put it everywhere so others will know.

I’m in the same boat, Airport won’t associate in 10.6.1 to either an 802.11a (who knew those were still around?) or 802.11b unsecured network.

I suspect that some part of the OS’s behind-the-scenes airport magic uses the address maintained by ifconfig (where-ever it’s stored), while other parts use a cached value (recorded before the command-line change), and the mismatch between them causes the network association to fail.

Has anyone using 10.6 tried the startup script posted by Jose Vigenor above? Maybe setting the MAC address before airport loads would be effective.

Of course, the *correct* solution is to get my IT department to revoke whatever ridiculous MAC-filter they’ve put in place and forgotten about, but I had hoped I could skip ahead of bureaucracy’s sluggish pace.

Well, I’ve given up waiting and have returned to Leopard. I figure I’ll just wait till Snow Leopard adapts it, cause mac address spoofing has more value to me than snow leopards minute upgrades. That being said, i’ll be sure to post if I find something useful (on the web).

In response to Cool P and his question on if someone knowing your mac address will make you vulnerable to being hacked. The answer is no. The mac address is used to identify that device on the network. The main reason for spoofing (for me at least) is for network troubleshooting.

I’ve pretty much given up too. I carry a spare external portable drive that I can use when I need to. But it sucks to reboot and not use my normal system. I’ve bookmarked this site and will test and come back when Apple releases 10.6.2 or any other patch.

In the meantime, we should be vocal about this and make sure Apple knows that this is a problem for those of us who need to troubleshoot or gain access to secure networks that require us to use a specific MAC address range. For some of us, it may mean not being able to use a MacBook or MacBook Pro anymore.

I have been watching these comments ever since snow leopard release. I thought I’d add my two cents in.

First off I know many of the readers need this command so they can set their MAC to an acceptable range for their network. My laptop already works in my network, I am using the command as a quick way to reset my IP.

I have had success under 10.6.1 using the “airport -z” to disassociate my airport completely. (I had to use “sudo airport -z”). I then used the above command to switch MAC. I then am able to connect to my network just fine.

Also of note, after connecting to the network and running “ifconfig en1” (the grep part is not needed, just running “ifconfig en1” gives more information on your status) I get my personalized MAC address returned. However, when looking under System Profiler or Network Utility my original MAC is still listed.

This doesn’t concern me though since my goal was achieved, a new IP is assigned. Dunno how this affects the crowd of folks that need a certain range in order to connect in the first place.

Hey, I’m running 10.6.2. and I still haven’t figured anything out.. about how to make this work. I’ve tried everything recommended here with the only result that my macbook refuses to associate with a network when I do the MAC address change.

I remember there was a airport driver extension hack a while back that would change it manually in the driver because there wasn’t another way… this is before you could assign it with airport -a , which apparently doesnt work anymore . Does anyone know if you can still use this trick ?

Everyone, this definitely still works because I am spoofing my MAC right now in Snow Leopard. Follow the instructions carefully, make sure you DO NOT split this command into 2, it looks like two lines in the article for some fontsizes but as the author says it is one command string to the paths, you are linking the airport application to /usr/sbin so you can use it by just typing ‘airport’ or as one commenter said ‘sudo airport -z’ since you need the admin privilege to run it.

Breaking down that command is this:

sudo ln -s (create the link)

/System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport (the path to the airport utility)

/usr/sbin/airport (where the link ends up so you can just type airport)

but it is all in one! DO NOT forget this! sudo ln -s path destination is the format!

then sudo airport -z and you are dissasociated….

The secret is doing that properly, because you HAVE TO DISASSOCIATE from the network but still have Airport enabled!

Trust me this works, doing it now by following exact instructions above. I have to spoof my MAC address nearly every day to get my MacBook Pro to be able to use the ATT hotspot at Starbucks (register on iPhone, spoof iPhone MAC, walla you have free WiFi at Starbucks)

I have Snow Leopard (10.6.2) followed the directions to the letter, and it worked fine. i also notice is still listed in System Preference as the one hard wired to the logic board. i guess that a good thing. ;)

Hello dear Mac Users :) I was trying to do exactly what said Chromeo. But nothing. I will try to explain what i’m doing.
1) Open Terminal.
2) Paste “sudo ln -s /System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport /usr/sbin/airport” (without quotes).
3) Enter. After that I have message: “ln: /usr/sbin/airport: File exists”.
4) Then typing airport -z.
5) Enter. After that I have message: “root required to disassociate”
6) Then “ifconfig en1 ether 11:22:33:44:55:66”.
7) Enter. After that I have message: “ifconfig: ioctl (SIOCAIFADDR): permission denied”
P.S. I have latest firmware of the airport (2009-002 v1.0). Help please.

Question, when I try these commands and various combinations of them: en0 etc., it doesn’t seem to apply. When I grep ether it tells me what i input, but when I check system preferences it’s the same ethernet. I’ve tried this command in root and superuser. Help please?

1. when i look system preferences->network->airport->ethernet, is still shows
my original Mac Address. is this normal?
2. after i rebooted the machine, the Mac address remains as the new one. is
this because this has been set permanently? the only way to go back to
the original Mac Address is issue this comment again
— sudo ifconfig en0 lladdr 00:00:00:00:00:00

I am also curious about this. I used another computer connected to my router to look up my computer’s MAC address and the spoofed one showed up. But the fact that it doesn’t change in system preferences->network still bothers me.

Im running 10.6 and noticed that nothing was working, in apps or in terminal. I found out you need to disable the airport by trying to join a non existent network, then pressing cancel. Then doing the commands to change the en1 mac. Its working on my macbook pro right now. Very happy there is a fix.

1. after you did that, what does it show in
system preference->network->Airport->ethernet? new or original Mac address
2. after you reboot your computer, do you need to do this again? i guess the spoof Mac address is for the current session only, right??

running 10.6.2 and I got the same issue:
I’m able to change my MAC address using “sudo ifconfig en1 ether 00:11:22:33:44:55” (with and without “sudo airport -z” as described above) but afterwards I can’t connect to wireless networks anymore. I’m getting timeout errors and I need to reboot before I can successfully reconnect to my wireless network.
any ideas?

Hi Dee Brown!
The tutorial is fine. I have 1 problem, hope to get solution from you. I have an optical internet connection(wire) which the ISP configured with my macbook (ethernet port), which means i can only use that macbook. Now i have 2 macbook and i wanna use both of them via WLAN.
so is it possible to clone the assigned MAC address into the Airport express so that i can use both of my macbook via wireless ?
Plz help

but the problem is that they configured using the MAC adress. now is it possible to clone MAC adress on Airport Express ( coz as far i know its not possible in airport express)
so, i wanna know if sumbd knows any trick to do so. ????

Thank you so much for this helpful tip! I had to use this when I moved my modem from my old computer to my new computer. For some reason, my modem would only work with my old computer.. I had to spoof the old computer’s MAC address on the new computer to get my modem to work with the latter.

So I tried AirportClown (there is a newer version than via your link) and it says it worked. Indeed, if in a terminal window I do:
ifconfig en1 | grep ether
then I also see that it worked. However, in the network preferences it stubbornly continues to see 7 use the actual hardware mac address of my late 2009 MacBook Pro’s WIFI (I’m running 10.6.4). I’ve heard the AirportClown method worked under 10.6.2, then it broke for 10.6.3 and was fixed, and now it’s broke again for 10.6.4 :-(.

and you are dissociated.
(If this does not work, go to the Airport icon, click join other network and type in some random SSID. It will say Connection failed and you are not connected )

Then set your MAC address to what you want:

sudo ifconfig en1 ether 11:22:33:44:55:66

Then Check if it worked.

ifconfig en1 | grep ether

These steps worked on 2 separate Macbook’s. With reboots. Note that after reboot that these steps will have to repeated. If there is a note of “access denied” Throw a sudo in front of the command. If “airport” is not found. Please read “NOTE” in original directions which will tell you what the command is… but i didnt have a problem with these directions.

[…] iPhone, from being able to access certain restricted networks with MAC address filtering to even spoofing a Macs MAC address in order to use WiFi that’s intended for iPhone and iOS devices only (such as the CLEAR iSpot […]

Hi, just have tried your MacSpoofer to change MAC address, and in fact it changes, but then, Wifi refuses to get same local IP address as before of making the change, so I am not able to connect to internet unless if reboot the system. Also, how can I contact you at your website ? (since I can not find any “contact” section)

since the spoofing command “sudo ifconfig en1 00:::::” is temporary (meaning: if you restart your mac the original hardware mac-address will be the one used by your os settings again) your airport advanced settings will show the original one Drew.

don´t worry ! if terminal shows the spoofed mac-address it is spoofed all right (:

I am having an issue with QuarkXpress 7.5 and having it run on system 10.6.4. From all the research I have done, the program crashes due to the firewire and its mac address. Is there a way to disable the firewire or to change its mac address. If so, please let me know. Thank you.

My notebook has a Atheros ar928X wireless card. I can not change the mac address successfully. I think the reason is the airport driver for ar928X. Snow Leopard gain the mac address from the firmware on the card via airport driver. If we typing “ifconfig en1 XX:XX….”, the mac address in driver is not changed actually. So I think, if you cannot change your airport mac address , you maybe other drive for you wireless card. My notebook can change mac address in Win7 when I use OEM drive.

[…] to create a new MAC address for something like your router or cable modem. Of course you can also spoof your MAC address rather easily in Mac OS X if you want to use one of the generated addresses for that purpose […]

I know that the public IP can be changed transforming the above cable-router into a cable-modem and then adding a neutral router, but what I am looking for is a way of changing the public IP using the Cisco EPC3825 alone.

After some web searching and trial and error I have figured out how to spoof both ethernet and airport MAC’s for 10.5.8 on my Macbook Pro. Airport must be on but disassociated as explained in previous posts. Ethernet works while you are on or offline, though if online, you will lose connection since your network settings have changed.

For clarification, the first 2 commands show the preset MAC addresses (I obviously censored mine, but you get the idea). Next I spoof the adresses and confirm it worked as I go. First is the ethernet (en0) and then airport (en1).

Correct me if I’m wrong, but this is the trick to get free Dropbox space, right ?
As I didn’t want to mess in OSX I used random MAC adresses before booting on a VM of Ubuntu via Parallels. Parallels lets you randomize a MAC adress in the pref of the VM. The only thing you gotta do, is doing it while VM is OFF, and you gotta reboot the VM each time you randomize.

Sorry, but this doesn’t work for the Ethernet MAC address, although it used to on 10.4.11. I can change it, but then I can’t connect to any web page, and if I reboot, it’s changed back to the actual MAC address.

That doesn’t help anyone, especially those that don’t have WiFi, and cannot upgrade to any other version of Mac OS X.

Spoofing is especially helpful for those who print coupons on the web, since most of the vendors use a system from Fox (as in Fox News) that requires the installation of some software, and then use Java to keep you from saving the file as PDF, and log your MAC address to prevent you from printing more than two coupons.

It would be nice to have a way to spoof the Ethernet MAC address that works again, by letting you load web pages after you’ve done it.

I do believe all the ideas you have introduced for your post. They’re very convincing and will certainly work. Still, the posts are too brief for beginners. Could you please prolong them a little from subsequent time? Thanks for the post.

My step father blocks my internet during day and only allows me to access the internet for a 2 hour period in the evenings. Will spoofing my mac address allow me to have access to the internet? He blocks only my laptop and iPhone, no one else in the house gets this treatment.

sudo ifconfig en1 ether 00:00:00:00:00:00
^^^ Set New Mac Address – FILL IN THE NUMBERS YOU WROTE DOWN.

ifconfig en1 | grep ether
^^^ Check Current Mac Address

^^^^^^^^^^^^^^^^^^

If the ifconfig shows you exactly the numbers you filled in, you are finished.

As long as you don’t shut down your Mac, it will look for the network, as you are your fathers PC/Mac.
You should being able to have now internet access all the time.

I hope i’m right, you can do this also with the MAC-Adress of your siblings.
If you want to figure the MAC-Adress on a Windows-PC just open “cmd” and enter “ipconfig /all”. Now have a look for the “physical adress”.

[…] received a few questions about this recently because the process of changing (sometimes called spoofing) these addresses has changed slightly from version to version in Mac OS X. With that in mind, we […]

Hey guys, I have a small issue when trying to change the mac address of en1 ether. I’m using the thunderbolt to ethernet adaptor and discovered that it has a different mac address than when using wifi. When trying to connect through the ethernet I get a parental control message (Linksys). I know if i change the mac address this will bypass it, but by performing all different sorts of methods above, including dissociating, trying different mac addresses, and so on. When I enter the command it goes right through, not asking for a password tho I’m using sudo ifconfig en1 ether xx:xx:xx:xx:xx:xx
When I enter the command to view the mac address it still reads the the old address. Its only with en1 ether as I can change everything in en0 and en1 wifi with no issue. Am I missing something? Please help? P.S. it needs to be en1 ether that has to be changed or is their a way to use the en0 ether address when using my thunderbolt to ethernet adaptor through my macbook air.

Does anyone have tried MacSpoofer ? I have tried that to change MAC address without using Terminal, and in fact it changes, but then, Wifi refuses to get same local IP address as before of making the change, so I am not able to connect to internet unless reboot the system to get restore original MAC. Is there anything I need to do on MacSpoofer ?