Isyour android emulator running on linux or windows? It looks at /etc/ linux, you can also use -dns-server xx.xx.xx.xx on the command line to set it manually. Does it output any warning message that it can't find a DNS server? Are sure the packets with IP addresses are coming from the apps like Instagram or whatever? – Thesteps are: The first one is using when you use your real android for me. Your Second opt is creating hotspot from your pc and connect your android device to the hotspot. Find the ip address using cmd type "ipconfig" replace localhost with the ip address. Toexit an emulator instance in Android Studio, you can follow these steps: Open Android Studio. is the localhost IP address for the Android emulator. It is used when configuring the Android emulator and connecting to databases from within Eclipse when developing Android applications. Changedirectory to android-sdk/tools. Issue the following command. ./emulator -port 5556 -avd AVD2_1_HVGA. AVD2_1_HVGA is my AVD name in Eclipse. You can see your AVD name by selecting the menu Window > AVD Manager. Share. Follow. edited Nov 13, 2011 at 23:11. answered Nov 13, 2011 at 4:16. TheIP address of the 'server' hosting the PHP script. The address (when used on an emulator) is translated to be the localhost address of the PC which the emulator is running on. If you take the emulator out of the equation, and assuming you're connecting to the 'server' using wired or wireless connection, then you need to use the HelloMy aim is to get the local address using the emulator sdk 2.2. I wrote this code but when I run it tell me to close the application. this is the code package exercice1.identificateur.ex; i Androidenables apps to learn about dynamic changes in connectivity. Use the following classes to track and respond to connectivity changes: ConnectivityManager tells your app about the state of connectivity in the system.; The Network class represents one of the networks that the device is connected to. You can use the Network object as a key iOS The iOS simulator uses the host machine network. Therefore, applications running in the simulator can connect to web services running on your local machine via the machines IP address or via the localhost hostname. For example, given a local secure web service that exposes a GET operation via the /api/todoitems/ relative Qi9PV.