Blogs
14 Dec 2022
Tutorial
2 mins read
How To Host A Web Server On Android

Firstly download and install localtonet mobile app:

  • Download localtonet app
  • Go Dashboard and copy AuthToken
  • Paste AuthToken on your app.

There are several ways you can host a web server on an Android device. Here are the steps for two of the most popular methods:

  1. Using a web server app:
  • Download and install a web server app from the Google Play Store, such as KWS Web Server or Simple Web Server.
  • Open the app and configure the server settings, such as the port number and root directory.
  • Start the server by clicking the "Start" button in the app.
  • To access the web server from a web browser on the same device, use the local IP address of the device (e.g., http://192.168.0.100:8000) or the loopback address (http://127.0.0.1:8000). To access the web server from another device on the same network, use the device's local IP address (e.g., http://192.168.0.100:8000).
  • To access from internet
  • Go to HTTP Page
  • Create tunnel Ip:127.0.0.1 port: 8000
  • Press start and you can now access the web server with the url given to you.
  1. Using a terminal emulator app:
  • Download and install a terminal emulator app from the Google Play Store, such as Termux or JuiceSSH.
  • Open the terminal emulator app and install a web server package, such as Apache or Nginx, using the package manager. For example:
apt update


apt install apache2
  • Start the web server by running the appropriate command for the installed package. For example:
systemctl start apache2
  • To access the web server from a web browser on the same device, use the local IP address of the device (e.g., http://192.168.0.100) or the loopback address (http://127.0.0.1). To access the web server from another device on the same network, use the device's local IP address (e.g., http://192.168.0.100).
  • To access from internet
  • Go to HTTP Page
  • Create tunnel Ip:127.0.0.1 port: 80
  • Press start and you can now access the web server with the url given to you.
Localtonet secure introspectable tunnels to localhost web development and local gaming