If you have the local IP address of a computer on your network, and need to get that computer's name, there is an easy method using the ping command in a Windows command prompt.

Command Prompt
Open up a command prompt by typing "cmd" into the start menu search (Windows Vista, 7, or newer) or by opening a Run window and then running "cmd" (Windows XP).

How To Open Windows 7 Command Prompt

Use the following command to ping the local IP address (change xxx.xxx.xxx.xxx to the IP address you want to ping):

ping -a xxx.xxx.xxx.xxx
The -a option of the ping command tells it to resolve the hostname of the IP address, so it will give you the name of the networked computer.

Here is an example of the output for a hypothetical computer named "Office1" that is at local IP address


C:\Users\Username>ping -a

Pinging Office1 [] with 32 bytes of data:
Reply from bytes=32 time<1ms TTL=128
Reply from bytes=32 time<1ms TTL=128
Reply from bytes=32 time<1ms TTL=128
Reply from bytes=32 time<1ms TTL=128

Ping statistics for
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms


Full Network Discovery

If you need to get the hostnames and other information for all of the PCs on your network, I recommend using Advanced IP Scanner.


How to Find Devices On Your Network

For Windows Users:

  • Type CMD in the search box and click Run as Administrator from the menu
  • Enter the net view command to view devices connected to your network You will then see a list of devices connected to your network in the output.
  • To view the IP addresses of the devices, enter the arp -a command, which will list the Internet address physical address and type of each device. You can then use ping these IP addresses to find the devices.

For Mac Users:

  • Go to the Applications folder and open the Utilities folder
  • Click on the Terminal to open it
  • Now enter the arp -a command to view a list detailing the LAN IP address and Mac address of each device.
Leave a Comment
No Comments found