I have for example this websites: https://ninja-copy.com/, http://www.amxmodx.cz, ... (choose first one) and I need to get IP Address of it.
Using cmd I pinged it, IP Addess is 188.166.116.95.
But the problem is when I try to connect to this webserver using my browser it returns status code 410 Gone
(in case of another one it's 404 Not Found
), which means website is pernamently deleted but it's still there!
How can I get IP Address from hostname?
(I tried changing ports too.)

- 371
- 3
- 12
-
Are you asking why you are able to access a website by name but not IP address? – Jason Dec 10 '18 at 16:53
-
Hmm.. Yes. I just want same effect with IP Address as hostname – loumadev Dec 10 '18 at 17:51
1 Answers
You can get the IP address for a hostname by doing either:
nslookup HOSTNAME
or
ping HOSTNAME
Using the IP address will work for some sites. With most sites redirecting to HTTPS these days it will be even rarer to get a page to load by IP address without a certificate error because you almost never see an SSL certificate with an IP address listed as the Common Name or Subject Alternative Name.
Most sites serve up content based on the host name. It's very common to have multiple sites behind one IP address and the host name is how the web server / reverse proxy / load balancer knows where to route the request behind the scenes.
And one last note. A lot of sites have begun dropping requests to the IP address or responding with HTTP error codes. Someone requesting a site with just an IP address is usually a pretty good indicator of them scanning the site for vulnerabilities.

- 475
- 2
- 4
-
Oh.. So It is not possible do it like this... Never mind, otherwise thanks for your help! – loumadev Dec 12 '18 at 16:38