Is there a way to get physical location of computer through MAC address?, I know switch's address and computer's mac address.

All this on a LAN network

  • this idea is pretty weird. We're trying to locate the place where the computer is connected, like geographic coordinates something like that. Only using the mac or ip address. Honestly, I think that is impossible, but I try to ask you if you know it's possible and exist a way. Mar 26, 2015 at 22:40
  • 2
    Your closest chance is to locate Layer 2 path to the final switch where the mac is observed and then...track physically the cable.
    – KorXo
    Jun 25, 2015 at 20:18

4 Answers 4


No, there is not.

MAC address are issued in blocks to network device builders and thats (usually) what you can infer from MAC addresses (who build the device), and thats all.

IP's on the other hand, can point to the general area where a computer may be connected to the internet.

Blocks of IPs are sold to Internet Service Providers and you can infer from the ISP where the device is connected to the internet.

There is something called a GeoIP database, that can correlate IP blocks (networks) to geografical locations. You might want to check with one.

  • An IP address won't give you a location either. Geolocation services are guesses at best. Down to city level is as far as most attempt, with varying degrees of accuracy. But "coordinates"? Not remotely. Even the find-my-device services need the device to have GPS to locate it to with a hundred feet.
    – Ricky
    Mar 27, 2015 at 0:35
  • thats why i added "reasonabe certainty" and " to the general area where a computer is connected to the internet.", is that giving the wrong impression ?
    – Jorge Aldo
    Mar 27, 2015 at 0:36
  • edited to give the right impression, geoip can err by thousands of kilometers margin. If i check my location with a common GeoIP service here, it claims that i am in another state...
    – Jorge Aldo
    Mar 27, 2015 at 0:40
  • There's no "certainty" in it at all. I've seen a lot of geoip lookups return the ISP HQ address because they have no better idea where an address actually is. ISPs can place addresses anywhere. A static IP assigned to a username (PPPoE) can be anywhere the authentication is accepted.
    – Ricky
    Mar 27, 2015 at 0:43
  • Dude, thats exactly where i tried to convey : " to the general area where a computer is connected to the internet.", what do you infer from this ?
    – Jorge Aldo
    Mar 27, 2015 at 0:55

As in locate a random internet device given it's MAC? Not a chance.

A MAC is a layer-2 address. Nothing beyond the local LAN (layer-2) segment knows, or cares, what that address is. For example, you have no idea what the MAC is of my computer. And even if I told you, there's no way to locate it on the internet.

Locating a single device within an enterprise network? The MAC can be found in switch tables localizing where it may be. Plugged into a specific port gives you a place to start physically looking, but patches can snake a connection all over the place.


If you have the ip address and it's on a LAN, look at the ARP Table of the gateway router to find the MAC.

Then with the mac address, find the source port of the mac, follow along and you will reach the switch it connects to.

Find the port on the switch.

Follow the cable.

  • He can probably just look at the ARP table of the switch without looking at the router. From there it is tracing the cable.
    – pooter03
    Jun 26, 2015 at 15:12
  • Unless the switch has had a reason to communicate via IP to the device in question, it won't be in the switch's ARP table.
    – YLearn
    Jun 26, 2015 at 18:04

You can do that by finding port of switch from which it's learning that mac address.

On Cisco:

sh mac address-table d | in MAC-ADDRESS (in xxx.xxx.xxx format)

On JunOS switch:

show ether-switcthing-table mac XX:XX:XX:XX:XX:XX

and this will give you physical port. You can trace cable from it to the system then.

I hope this will help.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.