Skip to content
All essaysA brass hourglass standing on an engraved map of a town, its streets, bridges and river drawn in fine lines

Mobile architecture

Mobile system design interview: a 45-minute framework for iOS and Android

One worked offline-first design, an inspection app used without signal, taken through a 45-minute interview minute by minute: the contract, ownership, sync failure, conflicts, storage, battery, rollout, observability, failure tests and the decision ledger you close with.

By Mike Salari. Staff mobile engineer · 500+ technical interviews from the hiring side.

16 min read

Design an offline-first field inspection app. A technician completes an inspection in a basement with no signal, kills the app, later connects to patchy Wi-Fi, and then edits the same inspection on a second device. The first phone resends its write after losing the acknowledgement. What should the user see, and what must never happen?

That is the system design interview. Not the boxes on the whiteboard. A credible answer must preserve local work, avoid duplicate effects, make conflicts visible, respect background restrictions, and allow a safe rollout to devices that will not all update together. The interviewer can assess those decisions within 45 minutes if you state your assumptions and make the failure paths explicit.

I am a Staff Mobile Engineer and Tech Lead with 15 years in mobile, and I have run 500+ technical interviews on the hiring side.

I use the worked inspection example throughout. The design is illustrative, not a claim about a real employer's application. Android's offline-first guidance gives a useful reference architecture, but the business invariants below are decisions for this example.

In the debrief for this kind of round, I write it plainly: "offline-first" is not evidence. I trust the answer when Saved, Pending, Uncertain, Accepted and Needs attention describe different obligations to the user. A candidate who can say which screen shows each state, and who resolves it, has designed a consistency promise. A candidate who draws a sync arrow has not.

Each platform has a full worked answer: the iOS system design interview and the Android system design interview. If you are unsure why this round differs from a backend one, read why mobile system design is not backend system design.

The 45 minutes at a glance

MinutesWhat you do
0 to 4Define a contract, not a feature list
4 to 8Draw the ownership boundary
8 to 12Show the design
12 to 17Decide how sync fails
17 to 21Define conflict ownership
21 to 25Account for storage and memory
25 to 28Battery and network constraints
28 to 32Rollout and kill switch
32 to 36Observability that does not expose private data
36 to 40Prove the failure paths
40 to 45Close with your decision ledger

The contract the diagram cannot make for you

For the inspection app, I would define the local save as the first commitment point. When the technician taps Save, the app writes the inspection data and an outbox operation in one local transaction. The UI reports "Saved on this device", not "Synced". If the process dies before the next network attempt, the edit remains recoverable.

The server does not simply accept "latest value wins" for every field. For free-text notes, the product might permit a visible last-writer policy with history. For a regulatory sign-off, silently overwriting either actor's approval would be unacceptable. I would model sign-off as a separate operation requiring an authoritative server precondition and surface a conflict for resolution. That costs an extra server round trip and more UI states. It buys a stronger audit boundary.

Every outbox operation receives an identifier before its first attempt. Retrying after a timeout sends the same identifier. The server must recognise duplicates and return the prior outcome or expose a reconciliation endpoint. This is not the same as exactly-once delivery. Networks can duplicate requests and lose replies; the design controls the effect by making retries safe.

Push notifications can signal that another device changed the inspection, but they are not the source of truth. If a notification is absent, sync still needs to recover through a cursor or equivalent fetch protocol. If a cursor expires, the client must reconcile from a trusted snapshot without discarding unacknowledged local operations.

I would reject a design that promises the operating system will wake the app every few minutes. Background scheduling is conditional. The core guarantee is durable local state and eventual retry when execution is permitted, not an invented schedule. Android's WorkManager guidance is explicit about persistent work and constraints. The iOS design needs its own platform-specific scheduling policy, not a copied Android assumption.

0 to 4 minutes: define a contract, not a feature list

The prompt is deliberately incomplete: "Design a mobile field-service app where technicians inspect equipment and submit forms, sometimes without connectivity." Your first job is not to draw boxes. State which actions must work offline. For this example, assume technicians can read assigned jobs, capture an inspection and attach small photographs while disconnected. A supervisor needs eventual visibility, not immediate synchronisation. Billing and destructive record deletion remain online-only.

I would say: "I will design around a durable local inspection and a clear pending-sync state. I am assuming a device may be disconnected for a working day. Before selecting storage, I want to know whether users can edit the same inspection on several devices, how much image data must be retained and which conflicts require human review."

I can now change a requirement. If the business requires instant authorisation for every inspection, the offline promise must be narrowed. Saying yes to incompatible requirements is not a senior answer. Put accepted assumptions in a decision ledger.

Make a decision: local editing is available, remote approval is not. The cost is a more complicated user-facing status model. The alternative, blocking writes until the server responds, is cheaper to implement but fails the primary field requirement.

4 to 8 minutes: draw the ownership boundary

I would make the mobile repository the boundary between feature state, durable local data and network transport. Views observe local records and their synchronisation state. Each submitted change becomes an operation in a persistent outbox. A worker reads pending operations, sends them to the server and records acknowledgement separately.

That means the same UI model is used when online and offline. The service is authoritative for approval and cross-device reconciliation, while the local database is authoritative for what this device currently displays. Those two forms of authority must not be confused.

The important decision is to make the outbox part of the same local transaction as the user's edit. Without an atomic relationship, a process crash can leave a changed screen with no queued upload, or an upload with no durable representation of what the user changed.

I would not introduce a separate synchronisation microservice on the device. It adds lifetime and consistency problems before the first reliable local transaction exists. Android's offline-first guide provides a useful platform model; the same architectural separation applies on iOS.

8 to 12 minutes: show the design

The diagram is an original logical design, not a statement that every production application needs each named module. Arrows describe data movement. The local transaction boundary is the most important box.

The logical design

  1. Inspection screen

    Observes local records and their sync state

  2. Repository

    Records the edit and the outbox entry together

  3. Local store and durable outbox

    One local transaction, the first commitment point

  4. Sync coordinator

    Driven by eligible pending work and scheduler policy

  5. Authenticated API

    Receives each operation with its identifier

  6. Server records and versions

    Acknowledges, and the local store and outbox are updated

An original logical design, not a claim that every production app needs each module. The feature gate and rollout policy feed the screen, and metrics and safe diagnostics observe the repository and the coordinator.

A user edits a field, the repository records the field change and outbox entry together, and the screen immediately displays "Saved on this device, waiting to sync." The coordinator never runs merely because the user opened a screen. It is driven by eligible pending work and scheduler policy. A remote acknowledgement marks the operation complete and updates the local projection.

The cost of this arrangement is explicit state and reconciliation logic. The benefit is a testable crash boundary and predictable offline behaviour. On iOS, the scheduler must respect platform background execution limits. On Android, durable work can use WorkManager when it fits the requirement. Neither platform promises indefinite background execution.

12 to 17 minutes: decide how sync fails

Give each operation a stable client-generated identifier and include the record version against which the change was made. The server retains a bounded deduplication record for operation identifiers. If the client retries after losing an acknowledgement, the server returns the prior result instead of applying the change twice. This is a contract with the backend, not a property the client can guarantee alone.

Split failure into classes. A transport timeout is ambiguous: the write may have succeeded remotely. Retry with the same operation identifier. A temporary server failure can use exponential backoff with jitter and an attempt budget. An expired session should pause work until authentication is restored. A validation error should stop automatic retries and present an actionable local state. A conflict should not be disguised as a transient network error.

The coordinator should process dependencies in the right order. An attachment upload may depend on the inspection record's existence. If that dependency is not explicit, retry behaviour becomes sensitive to timing. Avoid claiming global ordering when only per-record ordering is needed; global serialisation can slow every other technician's queue.

The cost is more metadata in local and server storage. The alternative is duplicate or lost business actions under normal mobile network failure. Android's offline-first data layer guidance describes persistent queues and synchronisation considerations.

17 to 21 minutes: define conflict ownership

Conflicts cannot be solved by saying "last write wins" and moving on. Here, suppose two devices update the same inspection while offline. A field-level merge is acceptable only if the business can show the fields are independent. If both users change the safety status, the app must preserve the competing values and request an explicit resolution from an authorised person.

Use server versions rather than trusting wall clocks on devices. Retain the base version with the queued operation. When the server rejects a stale write, provide enough information to present "Your change", "Current server value" and the next permitted action. Keep the user's original input safe while the dispute is unresolved.

The product must decide whether a previously approved inspection is editable at all. That is a domain constraint; the client should not infer it from a timestamp.

I would ask the interviewer: "Which fields can be merged mechanically, and who is authorised to resolve a safety-critical conflict?" This earns more confidence than asserting a clever merge algorithm without knowing the data's meaning. The cost is manual resolution for rare cases; the alternative is silently losing safety information.

21 to 25 minutes: account for storage and memory

An offline day with photographs changes the storage budget. Assume the business supplies a retention limit and an expected maximum inspection size before selecting a quota. Persist image files separately from the record index and avoid copying full images into database rows or in-memory UI models. Generate display-sized thumbnails and keep original files until upload is confirmed according to the retention policy.

Make low-storage behaviour explicit. A queued inspection must not claim to be saved if the device cannot commit the transaction or write the attachment. Show which records are safe to remove. Never delete a pending original because a cache eviction algorithm needs space.

Memory has a separate budget. A scrolling list must not decode dozens of full-resolution images simultaneously. Bound concurrent decoding, use thumbnails at display size and test on the lowest supported device tier.

This is not only performance work. If a field worker cannot complete an inspection because the app exhausts storage, the offline feature has failed. The cost is thumbnails, retention logic and storage monitoring. The alternative is a simple prototype that degrades under realistic usage.

25 to 28 minutes: battery and network constraints

Constant polling is the wrong default for a field device. Use scheduled, batched synchronisation with constraints that match the value of the work. A supervisor can wait minutes for routine notes, while a safety incident may justify a higher-priority attempt when the platform permits it. Distinguish urgency from a promise that the OS will always execute background code immediately.

On Android, WorkManager is designed for deferrable persistent work. On iOS, you must design around supported system background execution opportunities and foreground recovery. Both platforms can terminate processes, restrict background resources and change connectivity.

Measure bytes transferred per successful inspection, retries per operation and time spent in active synchronisation. An uncontrolled retry loop burns network, battery and service capacity in the same incident.

The cost of batching is freshness. State that cost to the product owner. A demand for immediate cross-device results is a different product contract from "works without connectivity".

28 to 32 minutes: rollout and kill switch

Treat an app-store release as only one layer of rollout control. Start with internal and limited cohorts, observe local database migration success, outbox backlog growth, crash signals and server error rates. Increase exposure only when those signals meet agreed thresholds.

A remotely evaluated feature gate can stop new entry into a defective flow. It must not delete pending work, strand a previously created record or require connectivity to open an already saved inspection. Define what the gate does while offline and how it behaves with stale policy.

The irreversible risk is local schema and data change. A staged rollout cannot make older app versions understand a new record format automatically. Design server compatibility and local migration safeguards before release. Specify when the old server contract can be retired.

A kill switch is not a substitute for recovery. If the new version wrote corrupt data, disabling the screen stops further damage but does not repair existing records. The decision is to favour reversible protocol changes and postpone destructive migrations until the new path has sufficient evidence. The cost is temporary compatibility code and operational ownership.

32 to 36 minutes: observability that does not expose private data

An offline-first system can appear healthy on dashboards while field devices hold unsent work. Count pending operations by age and error class. Record time from local commit to server acknowledgement, conflict rates, durable queue size, failed migration counts, upload sizes and user-visible blocked states. Segment metrics by app version and supported device tier.

Every operation should have a correlation identifier that is safe to log. Do not include form contents, access tokens, exact photographs or other private customer material in diagnostics. The client can emit safe breadcrumbs; the server can associate an idempotency key with the authoritative result.

A single global success percentage can hide the oldest stuck records. Alert on aged pending operations and a rising gap between local creation and remote acknowledgement. Combine automated alerts with an in-app recovery surface so a user can tell whether a record needs action.

The trade-off is telemetry cost and privacy review. The alternative is discovering sync failures only after a customer reports missing work.

36 to 40 minutes: prove the failure paths

I would test the same inspection under six faults: airplane mode before save, process termination after local commit, lost acknowledgement after server success, two devices editing the same field, exhausted storage during attachment capture and an app upgrade with a non-empty outbox. None of these requires an invented production incident.

For the most important test, terminate the process after the local transaction commits but before the sync worker starts. On restart, the user should see the saved draft and the worker should be able to resume using the same operation identifier. Next, allow the server to apply a write but drop its response. The retry must not double-apply the business action.

Make the test assertions user-visible: the draft remains present, no duplicate inspection exists, conflicting values are not silently overwritten and blocked records have recovery instructions. This is stronger than a test that asserts a particular worker method ran.

The cost is integration and fault-injection coverage. The alternative is trusting happy-path tests for a feature whose purpose is to survive failure.

40 to 45 minutes: close with your decision ledger

End the interview with three chosen trade-offs. First, local writes are durable and visible immediately, but server approval is delayed. Second, idempotent at-least-once delivery and domain-aware conflicts cost metadata and backend coordination but protect user intent. Third, staged exposure and compatibility code slow removal of old paths but make release failure recoverable.

Name the risks still open: limits on offline duration, attachment size, user authentication expiry, changes in support requirements and whether the server can store deduplication outcomes long enough. Ask which of those assumptions the interviewer wants to change.

My evaluation would focus on whether a candidate can defend these choices under the next constraint, not whether they filled every minute with components. A Senior answer shows an operable solution for one mobile product. A Staff answer shows how platform teams, backend owners, security reviewers and release operations can keep the promise together. If I cannot connect the choice to a user-visible state and an operator-controlled recovery path, I would mark the design incomplete.

A decision ledger the interviewer can challenge

Keep one small ledger on the side of the diagram: invariant, owner, cost, failure test. For example: "No inspection edit disappears after local Save; client transaction owns it; cost is storage and migration; test is kill after commit." A second entry might read: "No duplicate sign-off effect; server owns operation identity; cost is deduplication storage; test is accepted write with lost reply." A third covers cross-device conflict, with explicit user resolution and audit history. This makes the design inspectable without pretending every subsystem fits on the whiteboard.

What the interviewer is actually scoring

A weak answer names tools and mechanisms without establishing invariants. "Use a database, retry with WorkManager and add a cache" is not enough. It leaves open whether a user action survives process death, whether retries duplicate server effects and whether an offline edit is safe to present as final.

A strong answer starts with the user promise and keeps checking whether each design choice protects it. It also names the cost of the promise. Offline work requires local storage, durable operations, authentication boundaries, synchronisation and support for states that are neither success nor simple failure.

At Staff level, I would listen for the cross-team contract. The mobile and backend systems must agree on operation identity and conflict semantics. Product owners must approve what "saved" means. Security owners must define what stays on the device. Release owners must be able to halt new exposure without destroying old work.

For your own preparation, record a five-minute version and a forty-five-minute version. If the short version cannot name the main invariant and three most expensive decisions, the full presentation is probably hiding missing priorities behind detail. Use the same five-minute account to challenge your own design: which promise can the user verify offline, and what breaks after the process dies?

Questions engineers ask about the mobile system design interview

How should I spend the 45 minutes of a mobile system design interview?

Define the contract in the first four minutes, draw the ownership boundary by minute eight and show the design by minute twelve. Then decide how sync fails, define conflict ownership, account for storage and memory, battery and network, rollout and the kill switch, and observability. Spend minutes 36 to 40 proving the failure paths and close with your decision ledger.

What is a decision ledger?

A small list kept beside the diagram with four columns: invariant, owner, cost and failure test. For example: no inspection edit disappears after local Save, the client transaction owns it, the cost is storage and migration, and the test is killing the process after commit. It makes the design inspectable without pretending every subsystem fits on the whiteboard.

What does the interviewer score in a mobile system design round?

Whether you establish invariants, not whether you name tools. A strong answer starts with the user promise, names its cost and keeps checking each choice against it. At staff level the interviewer also listens for the cross-team contract between mobile, backend, product, security and release owners.

To practise this as a full design answer, with exercises and model answers, use Mobile System Design Blueprint.

Related resources

Free resources that put this essay to work: short enough to use this week, and each one works on its own, with or without a book.

Related books

These books take the subject of this essay further, written from the hiring side from 500+ technical interviews. Each book page shows what is inside, who it is for, and a free sample where there is one.

Share this essay