Optimum offline handling in a mobile app

In short, do this:

  • Cache the data locally and use that instead of the data from API
  • Display a persistent banner/notification to let the user know that the data may be stale and the app is offline
  • When user navigates to a page which needs data not in cache, display a full page error
  • When user takes an action such as submitting a form, provide feedback to user that the app is offline and cannot do this. Feedback can be in the form of a toast message or notification.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store