Should your phone be a webserver?

I really like this article from Rohan D "Every Phone Should Be Able to Run Personal Website".

In it, they make the convincing case that phones are perfectly capable of hosting websites and - if we want more people to escape the walled-gardens - this could be a good way to get people back into self-hosting.

I loved hosting a small site on my Nokia N95 back in the day, and I'd be overjoyed if modern phones allowed this. But there are a few pitfalls.

Connectivity is the main one. If you're sat at home on WiFi all day, or only ever in an area with good cellular reception, then this is great. But the second you get on an underground train or climb a mountain your website goes offline. Perhaps it might be nice to introduce a little randomness into our sites' availability. But most people want their site to work even if their phone is in a deadspot.

Cost is also a factor. If you're on an unlimited data plan, then you're fine. If you're on a cheap PAYG plan with only a few GB then your website becomes a liability. If one of your links becomes suddenly popular, you might burn through your monthly limit in a few minutes.

Battery life is the next big problem. Again, if you're sat in an office all day with your phone plugged in, you're fine. But if you're out and about, running a server and delivering data is power-hungry. Do you want your phone to die because your cat photo went viral?

Security also becomes a factor. Web servers are constantly under attack. Will your private data be compromised if your phone's webserver hasn't received the latest patch? And if an attacker gets onto your phone, can they then infect the rest of your home network?

All that being said... I still like the idea! I have a few old Android devices which I use as IP Cameras. They stream pictures and videos across my local network - and I can control them over a web browser when I'm at home. But would I want to expose them to the whole Internet? No!

With the price of SBCs coming down, I think it makes more sense to have a "website in a box" device. A little Raspberry Pi which is only running enough of a server to power WordPress or similar. Hardened against attack, and easy to manage and edit from a cheap mobile phone. Perhaps give it battery backup and a SIM card if you want redundancy. Boom! Instant personal webserver.

Yes, our phones should be under our control - and I certainly support anyone who wants to run a server from their device - but it seems to me that there are several hurdles which make it impractical.

Share this post on…

7 thoughts on “Should your phone be a webserver?”

  1. says:

    Your article reminds me of a brilliant 'Dangerous Demo' that we did for an Open Source event in Madrid a few years ago.....

    I managed to scrounge half a dozen Ubuntu handsets from Canonical (when they were playing around with producing their own mobile Ubuntu as an alternative to Android).

    I challenged a number of the 'Best of the Best' developers to throw something together in less that 24 hrs to show off what could be achieved with such a modest platform.

    Straight away, Daniel Mierla (Founder and titular leader of the Kamailio Project) got engaged - and next day produced an eye watering demo in which he provided a complete mobile network core, which was then interfaced to a Lime Micro SDR in order to provide a low power 3G network in the underground ballroom in which the event was taking place. Not satisfied with capturing all of the phones of the udience, he then proceeded to load up the RAN with additional trafic, until the whole thing red lined (or burst into flames).

    I was amazed at how much traffic such a cheap, low spec device, could handle!

    The Ubuntu handsets were on loan from Canonical - but Daniel's demo was just SO GOOD that I decided unilaterally to award the device to him as a prize!

  2. said on

    @Edent i mean, the security concerns set off a lot of red flags for me, but setting that aside,
    you can already put apache on android. I think the hard part is making it consistently reachable via URL, as your IP address will change every so often. That, and i think cell providers might be blocking that exact kind of incoming traffic, but i'll be honest, i haven't checked in over a decade at this point.

    Reply | Reply to original comment on
  3. Put a static HTML website on a SanDisk Connect USB, which is basically a WiFi microserver with a battery in a USB flash drive format, with the data actually being on a microSD card:

    One serious use case for web servers on phones is in countries like Iran or Saudi Arabia where information dissemination carries real risks. When combined with flash mobs, it's this century's answer to Samizdat. Then you have the people seeding flash drives with entire copies of offline Wikipedia in .ZIM format in North Korea.


What are your reckons?

All comments are moderated and may not be published immediately. Your email address will not be published.Allowed HTML: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <p> <pre> <br> <img src="" alt="" title="" srcset="">