Android - Can I run a webserver on an android device?

Absolutely! You can either:

  • download a ready made one - like kWS - Android Web Server or
  • write your own - here's some code to integrate in to your project or just use as is.

The book Pro Android Python with SL4A comes with some free downloadable source code, you can find it on that official site. In the source code samples there are examples of basic httpserver, and basic ftpserver. Both of those will work on Android devices, I imagine it is also possible to make a more advanced webserver using python, or perhaps even re-purpose one that is already in existence.


There are actually several apps on the Google Play Store. A few of them even have PHP. My personal favorite is Servers Ultimate.

Tags:

Web Server