All Articles

Why Your Business App Needs Offline Mode

Posted 2018-09-13 03:09

9 minutes to read

Mobile Team
Mobile Team at Rozdoum

Smartphones are now associated with the word ‘mobile’, whereas they are preferably a response to an increasingly fast-paced lifestyle.

There are a lot of spheres that were created mobile: postmen, inspectors, researchers, paramedics, sales agents, repair crews, engineers, officers, deliverymen, couriers, and the list goes on and on. We have gotten used to smartphones as being a communication device, a source of information, and a working tool. Business mobile applications are perfect assistants, primarily when you are working in the field. Dead zones, loss of internet connection and blackouts are the main obstacles out-of-the-office workers face. Mobile applications with an offline mode can help your business, and your employees perform productively, regardless of the challenges associated with a bad or absent internet connection.

offline mode in mobile app - rozdoum

Typical scenarios when an offline mode can help

An arduous path of navigation

  • Imagine that you have a pizza delivery business, and a customer ordered a pizza. The delivery man sets out on his journey, but does not know the location of the order, he reverts to using GPS-navigation to reach the location but loses the connection along the way. If your customer were to receive a cold pizza, then naturally they may demand some satisfaction. Offline maps for pizza boys will consequently enter your list of requirements if you decide to create a mobile application.
  • Another example: You are going on a date. The date is scheduled, but you don’t know where the restaurant is located. You rely on online maps and build a route. On your way, you enter a ‘dead-zone’, where your phone can’t connect to the network, causing you to lose your way, and thus making you drastically late for your date. Probably not the best way to start a date, especially if it is the first one.
  • Your job in your pocket: Your engineers have to construct a new cell tower in the field. You want to streamline their workflow and provide all necessary construction information paperlessly. What’s the solution to this? Investing in an offline business app will allow you to supply them not only with coordinates and resources but with the correct amount of offline data as well. The engineering plans can be cached on their mobile devices, along with the tower drawings.

Somebody mixed my medicine

  • Saving lives: Let’s say somebody has some health conditions that may require urgent medical assistance. This person downloads an app in order to call an ambulance with one touch, and deliver a preset message to emergency contacts. This app can provide doctors with relevant info on the patient’s health condition along with the history of their activities. It can show the user the location of the nearest hospitals if it is not an emergency. Such an app would be just useless without working in an offline mode.
  • A doctor’s case: All the information about your patients is gathered into a huge database stored on a server. Unfortunately, your hospital suffers from a blackout, due to some unpredictable circumstance. You have emergency backup generators to help, so it is not a disaster yet. Still, if your tablet or system cannot reach the server to retrieve the necessary info, and there is no offline logic foreseen for health information, then it would become a disaster.

Must have my precious back

  • Dealing with money: On your way home after a long working day, you decide to save some time and buy a present along the way, for example. (Or make your house utility payments, or spend some money on whatever else). Suddenly a Wi-Fi station in the subway train stops working, precisely at the moment when you finish all the confirmations and push the final ‘Pay’ button. You may not know where your money goes if there the banking app does not have an offline mode. The banking app with an offline mode may save the transaction details locally. It may show you a notification informing you what will happen next with your money and may try to finish or cancel the operation when the connection appears again.

Offline mode is for people who can’t afford to be offline

A loss of connection is annoying, but it is not a dead-end. Turn a blackout from working against you to working for you. Offline mode is the feature. It helps users ease their worries about how your application functions, giving them an experience that does not depend crucially on the connection. If your business app’s user activity is not interrupted due to an internet outage, then it will boost their productivity, and your business will benefit in response.

Requirements of an ideal offline mode

Unfortunately, there is no universal solution, one-for-all remedy or any magic beans to build the perfect offline mode for your application. It certainly takes doing your homework, but there is an algorithm which will help you. First, analyze your workflow and define your vital business needs which will be then transformed into functions of your app. Make a list of them, prioritize them as blockers, critical or minor activities. Describe what result you are expecting from your app as well as from each user, and if it is possible, mark possible results as well. Determine what the best possible outcome is, including the appropriate and unacceptable results. Document every one of your steps:

  • workflow description,
  • users activities with their prioritization, and
  • your expectations.

Such a document will help your development contractor to consult you and offer the right technologies and a tailored solution.

Hard choice of techniques and technologies

You may not know how to code, but your developers do. That is why no matter how tedious or complicated their terminology is for you, try to figure out the meaning. Depending on your requirements, documents, and desired result, your contractors should discuss with you the following details. They are not ‘small talks’, this information is crucial for implementing app’s offline mode.

  • What data should be synced? Smartphones are powerful devices, but they are not servers, so it is best not to overload them. To ensure the smooth performance of your app, make sure you store the least possible amount of the data locally.
  • How often should you sync the chosen data? Attempts made to reconnect too often may over drain a mobile device’s battery. On the other hand, if the app synchronizes rarely, users may miss significant updates. You should find that balance with your developers.
  • When should it synchronize? For example, public transport carriers prefer to perform a full synchronization when vehicles are in their depots. They transfer only some of the most critical data, like accidents on a route. That is where your workflow description will help.
  • What is the priority of data sync? You need to determine which data is less important and which is critical in order to provide your app users with a proper offline experience.
  • Where do you store the data for sync? Keep in mind that mobile devices are not datacenters or servers. Try to find the least possible way to load a mobile device with offline data, and make a server do all the work.
  • How do you manage changes and resolve conflicts? You may not need to update all the data: perhaps just the changes, maybe you need to synchronize the shared data only or store personal data locally. There is always a choice, but it may have a negative impact on your app’s performance and your device’s battery life.
  • How do you handle modifications of offline data? You may change access permissions for the data when the app is offline. For example, if you deal with sensitive information, all the cached data may have read-only permission, until a connection appears.
  • And, at last, how do you sync? Should it be synchronous or asynchronous, auto-sync or manual sync? Will your app be actively asking the server for updates (pull requests), or it would be a server that transfers new data to an app (pushes).

Building an offline mode

The implementation of offline sync for your app may differ from the picture below, but the mentioned approach is universal. Using SQLite locally for managing data, and REST-based server side is a common solution. It is flexible and allows for the addition of any specific scenarios to customize your app.

rozdoum article - offline mode

Offline sync checklist

In order not to miss some critical functionality of an offline mode for your app, check the list below:

  • You defined the smallest amount of data stored locally.
  • You determined the least possible info to transfer from the server to a device.
  • You set the trigger to initiate a sync, manually or background.
  • You configured your conflicts resolution.
  • You identified and prioritized the data sets that should be synced.
  • You specified the factors that will pend a sync.
  • You struck a balance between the frequency of the syncs and the battery efficiency of a device.
  • You worked out the retry mechanism.
  • Your users receive a sync status notification.

Reasons to build offline mode

Despite the era of technology, connection loss and outages happen, and as such smartphones temporarily seize to exist as a working tool, assistant, and mini-computer. If the essence of your business is innately mobile (that is, it requires your employees to move a lot), then you need a business app with an offline mode. An offline mode is a way to boost productivity by providing users with the core functionality available anytime and everywhere. With it, your users are engaged in an uninterrupted workflow, and your business will benefit tremendously.

If you are not sure where to start with a mobile app for your business, we are ready to help. Refer to our clients’ cases, try our calculator, and drop us a message to share your ideas.

Mobile Team
Mobile Team at Rozdoum