You might want the IP address of a domain name so you can put that in your local host file. A very easy way is to use ping command in command prompt
PING ds-any-fp3-real.wa1.b.yahoo.com (184.108.40.206): 56 data bytes 64 bytes from 220.127.116.11: icmp_seq=0 ttl=248 time=408.454 ms 64 bytes from 18.104.22.168: icmp_seq=1 ttl=248 time=328.405 ms
The IP address is in red. Works in both Windows and Mac.