Android Networking Interface Information or What is my IP address?

If you want to know what your IP address is while on your Android phone, and you have terminal, then you might try as I did tonight. I opened up a terminal application and tried:



ifconfig -a

Nothing again! Searching I found that I needed to specify the name of the network interface, or else it would not work. I also discovered that I could find all the names of interfaces by doing:

ls /sys/class/net/

So, for most phones the name to use from this list is eth0. To find out my IP address on my phone, I finally ran in my terminal application:

ifconfig eth0

I even tried this without root access, and it works!

About Me - WrightRocket

My photo

I've worked with computers for over 30 years, programming, administering, using and building them from scratch.

I'm an instructor for technical computer courses, an editor and developer of training manuals, and an Android developer.