Connect Android with Localhost / Apache Server – Linux

Old No Comments on Connect Android with Localhost / Apache Server – Linux 38

Hello geeks,
in this tutorial I want to show you how to connect your Android application with your computer.

Let’s start!
Connect over …
Wi-Fi:
Okay, simple! Just connect your computer and your mobile device to your router. If both are successfully connected open the terminal and type in:  “ifconfig”.
This command will show you your IPs and other information about your network. But we just need an IP.
If you put the command in it you’ll see under “wlan:” the “inet addr: 192. … “. Open your browser on your device and type the IP in the URL. Your index file on your server should show up.

Mobile tethering:
Same thing, just connect your computer with your device (USB). Start the mobile tethering in your settings, open the terminal and type in: “ifconfig”.  After that, copy the “inet addr:” but this time it’s under USB.  Test it out with the browser again 😉

Thank you! 🙂

Author

Kawa Acikgoez

I'm 16 year old dude from Germany programming in PHP and Java (Android).

Related Articles

Leave a comment

Back to Top