Java Program to Get IP Address

By: Editorial Staff | Last Updated: | In: Java Tutorial


This is simple Java program to print the IP address of your computer. If you want to get the IP address of your machine, then keep your close attention in this tutorial as we are going to share a Java Program to Get IP Address with an example and output.

Java Program to Get IP Address

Copy the below Java program and execute it with the help Java Compiler.

Program Output

javac IPAddress.java
java IPAddress
124.253.78.30


About: Editorial Staff

Editorial Staff at FreeWebMentor is a team of professional developers leads by Prem Tiwari


Tags: , , , , , ,