java.net.InetAddress inetAdd = java.net.InetAddress.getByName("www.ibm.com"); System.out.println ("IP Address is : " + inetAdd.getHostAddress());