How to find hostname computer or machine name from IP address in command prompt
Find a Hostname for an IP Address : Its very common requirement to know IP address or host name of network machines. Here are the steps to know public or private IP address or host names-
How to find website IP address from name : – If you know the domain name i.e google.com and want to check its IP address you can do below –
- Open command prompt
- On the command prompt and type : Ping www.google.com
- It will show google website IP address.
How to know IP address of local network machine : If you know host name or machine name of your internal network machine, you can get IP address also –
- Open Command Prompt
- On the command Prompt type – : ping Machine name
- It will show IP address of that machine.
How to find hostname from IP address : If you know host name or machine name then also you can find IP address of that machine-
- Open command Prompt
- On the command prompt type : ping -a IP_address or nbtstat -A IP-address
- I have shown two different commands in step 2. They both will work and show IP address of that machine.
If you have setup DNS in your network then you can use below method to know IP address and Hostname :
- Open Command Prompt.
- On command Prompt type : nslookup ipaddress or nslookup hostname.
- I have shown two commands in step 2. They can be used to know host name to IP address and IP address to Host name.