Offline-First Mobile App Development
Offline-first mobile development: SQLite or Realm storage, sync and conflict rules, queued actions, media caching, and testing on unreliable networks.

An app that shows a spinner the moment the connection drops loses whatever the user was doing: the order being placed, the inspection being filled in, the note typed on a train. For a delivery driver, a field technician, or anyone working in a basement, that decides whether the app is useful at all.
Offline-first changes where the data lives. The app writes to the phone first, screens read from the local store, and actions taken without a connection wait in a queue until the network returns. The hard parts are the merge rules, the storage budget, and what the user sees when a request dies halfway through.
Who this is for
- Field service, inspection, and audit apps used where there is no signal
- Delivery, logistics, and ride products where status changes happen on the move
- Audio, video, and reading apps that download material for later
- Retail, hospitality, and clinical tools used inside buildings with thick walls
What we deliver
The local store
The database follows the data model rather than a habit. SQLite through Drift, Room, or WatermelonDB covers records with relationships and queries that grow. Realm and similar object stores fit document-shaped data and report changes with little code. Tables, indexes, and migrations get the same care as the server schema, since a released app cannot be force-updated when a column is renamed.
Sync in both directions
Sync pulls what the device has not seen and pushes what the server has not seen. A per-record server timestamp keeps a pull to what is new instead of re-downloading the collection. Pushes carry an identifier the server has already seen, so a retry after a timeout updates a record rather than creating a second copy. Sync runs at app start, on connectivity changes, and on a background schedule where the platform allows it.
Conflict resolution, with an example
Two technicians open the same work order before either has signal. One marks it as waiting for parts and photographs the part number. The other adds a note and corrects the quantity on a line item. Both phones keep working, and both sets of changes reach the server later.
Our default is a field-level merge, because fields are where the meaning sits. The status change and the note touch different columns, so both survive. Line item quantities travel as adjustments rather than absolute numbers, so a correction from one device and an addition from the other both apply. Where two devices genuinely write the same field, the server keeps the change with the later server timestamp and stores the losing value in a change history the app can show: one technician set the status four minutes before the other edited it. Fields that must not merge have a single writer, so an approval state or a recalculated order total never becomes an argument on the phone.
Queued actions, media, and cleanup
Every action that needs the network enters a persistent queue with its payload, order, and retry count. The queue survives restarts, shows the user what is still waiting, and replays in the order the actions were taken, since a status change and the note attached to it stop making sense once reordered. Failures split into ones worth retrying, such as a timeout, and ones that never will succeed, such as a rejected payload or an expired session, which return to the user with an explanation.
Media gets its own rules. Uploads resume from where they stopped, downloads carry a size estimate and a Wi-Fi-only option, and a half-finished file is stored apart from the finished one so the app never plays an incomplete item.
The app also gets a storage budget. We cap the database and cache, evict downloaded media on a least-recently-used basis, and expire content after a period the product team agrees. Queued writes stay outside cleanup, because deleting the only copy of a user's work is the worst bug this kind of app can ship.
Testing on unreliable networks
We throttle bandwidth and drop packets on real handsets, switch to airplane mode during a sync, kill the app mid-push, and change the device clock. The sync engine also runs in automated tests against a fake server that fails, delays, and reorders responses, so retries, duplicates, and partial merges are exercised on every build.
Where the project starts
A plain idea, where nothing exists yet. We design the local schema and the sync contract alongside the first screens, because the shape of the data decides how much of this work there is. A small product can start with one local table per record type, a queue, and full-record sync, then move to field-level merges as the data grows.
An existing conventional codebase. We read how the app fetches and caches today, then work inside it. Common findings: an API call on every screen open, no local persistence beyond a settings file, a retry loop that duplicates submissions, and full-resolution images kept forever.
An AI or vibe-coded prototype, where screens arrived faster than the plumbing. These builds often keep state in memory only, call the network straight from the interface, and lose user input on a rotation. We keep the product thinking and the parts that work, then add the local store, the queue, and the merge rules underneath.
How the engagement runs
Discovery covers the records that matter and the places users lose signal, since those answers set the scope. We map every read and write, decide which must work offline, and write the sync contract down before implementation. The build runs in phases: local store and reads, then the write queue, then conflict rules, then media and cleanup, with testing on throttled connections alongside each one.
What it costs
Work runs at our flat rate of $39 per hour, or as a fixed scope once discovery has produced a real list of records and flows. A mobile app MVP ordered as a whole typically lands between $4,800 and $8,500 across four to six weeks, and the pricing page breaks that range down next to our hourly rate and monthly capacity plans from $2,699. Offline support inside an MVP usually costs a phase rather than a second project.
The scope drivers are countable: the number of record types needing sync, whether merging is full-record or field-level, how much media users download and keep, and whether your API needs a record version or a safe way to accept a repeated submission.
Proof
AccuLevels is a precision measurement app for iOS and Android, built in React Native around the accelerometer and gyroscope, with a calibration flow so readings stay consistent across devices. Its numbers come from the handset itself and appear without waiting on anything remote, which is what a local store demands once the device becomes the source of truth.
Epic Story is a historical audio app with narrated stories, ambient sound layers, and downloading for offline listening, plus cache management that keeps storage in hand without asking users to manage it.
Walking Cure was a WordPress clinic site for a California practice, with sections explaining a walking-based health method and a blog for ongoing content. The content structure was decided before anything was built, which is the question an offline cache inherits: what a reader needs, and at what size, when the connection is gone.
Related services
- Mobile app development covers the iOS, Android, and Flutter builds offline features sit inside
- Mobile backend and cloud infrastructure for the server side of sync: data model, versions, and the endpoints the queue replays into
- Mobile location and maps integration for apps that keep recording position through tunnels, basements, and dead zones
- Progressive web app development when the browser is the delivery target and service worker caching does a similar job
- API development and integration for adding record versions, idempotency keys, and delta endpoints to an existing API
Next step
Tell us which screens your users need when the signal is gone, and what the app does today when the connection drops. We will say which records have to live on the phone, what merging them involves, and what the first phase would cover.
Contact us with a short description, or run your requirements through the Vasilkoff.info estimator for a first scope and cost range.