It’s moving slowly, but offline apps are happening. The times when your app would be a glorified reflection of your website in native code with barely any functionality without an Internet connection are no more. Your app should work offline as well as it does online and it should pass the Tube Test.

The Tube Test is a simple concept. For those who live and/or commute in London, perhaps the most prolonged period at which they stare at their phone during the day is when they are on the bus or the underground. When it comes to the latter, they experience sporadic connectivity – they scramble to connect their devices to the wifi at each station, download whatever it is they need for the duration the train will be in the tunnel (and without any connection), enjoy the content whilst offline, then any actions they perform whilst offline are executed once connectively is reached at the next station.

This is important for a simple reason – surely any mobile developer aspires for their app to be the one people open on their way home from work without a second thought? If it’s not usable on the tube, or if it frustrates users when it has poor connectivity, you’re ruling out the one period of the day where users have absolutely nothing else to do but stare at their screens (commuters don’t talk to each other… come on!). Facebook is offlining, Twitter is offlining, the Guardian is offlining, any app worth its salt is offlining.

You don’t even need to do it all in one go. If you have an app that allows users to interact with each other, why not just offline the messages? Then maybe later you can offline the public feed. In fact, why not make it really simple to begin with and just flush the SQLite database (common to all Android devices), refilling it entirely when the app loads? Then have offline as an insurance policy – if the user is online, call the API. If not, load from the database. It takes such a basic change and you can migrate slowly, giving users immediate benefits from the smallest amount of initial work.

If you want a simple tutorial on using the SQLite database on Android (which is a lot simpler than it sounds, I promise!) then I can heavily recommend the excellent book by Commonsware – which every Android dev should have a subscription to. It’s kept up to date with the absolute latest on Android and costs pennies for what is a very comprehensive online resource. Just write a simple database helper to create the schema and get/set the data, accessed from background threads, then you’re done!

When I was preparing a presentation on this for my workplace last week, I tried sending the mandatory photo of my cat standing in front of my PC monitor (purr programming… No? Nothing?) from my Gmail app on my phone. After wondering why it hadn’t turned up in my work inbox five minutes later I realised that I’d turned mobile data and wifi off to test the dev work I’d been doing that day on our own app. The experience with Gmail was so seamless I didn’t know whether I was offline or online. That has to be the goal for any app developer in 2015: to provide an experience so smooth that the user cannot distinguish when your app is running online or offline. This is the criteria that will decide which apps survive and which get left behind.

Categories: Uncategorized

1 thought on “Offlining your apps and passing the Tube Test”

Adam Bolton · September 29, 2015 at 11:21 am

Hi Chris, good read. Like the concept of the Tube Test, it’s so true!

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Posts

Uncategorized

Why the Lib Dems should vote for all-women shortlists – from somebody who used to oppose them

(…Or how I stopped worrying and learnt to acknowledge my privilege) [NB: I realise I’m not in the Lib Dems anymore and therefore I don’t have an internal vote/say on the matter. If you’ve come Read more…

Uncategorized

A depression-suffering Labour member writes: Ken’s “apology” is not good enough

I’ve suffered from depression for about two years now. I have a similar story to most – some days are better than others, but the treatment does wonders and helps me identify triggers that are Read more…

Uncategorized

Hackathons: they’re fun, but they need to change

I’m very lucky to have a (current) winning streak when it comes to Hackathons. At Intertech LGBT’s hackathon in 2014, we were joint winners of the first prize and a couple of weeks ago, we Read more…