Firebase offline: What works, what doesn't, and what you need to know (Firebase Summit 2019)
Why Stack Overflow recommends it
Stack Overflow users link it when answering questions about what Firebase services do offline, such as write queuing, cache limits and the roughly 72 hour analytics data window.
Recommended by 2 people across 3 different months, 2020 to 2025.
What it is
A Firebase Summit 2019 talk by Susan Goldblatt and Todd Kerpelman on how Firebase products behave when a device has no network. It covers offline caching and write behavior in the Realtime Database, Firestore, Analytics, Performance Monitoring and Crashlytics, plus common pitfalls.
What people said
Recommends jthegedus · 2020-09 · Stack Overflow · on “Does Firebase Analytics Work Offline?”
Sept 2019 source: Firebase offline: What works, what doesn't, and what you need to know (Firebase Summit 2019) [this video] Performance Monitoring & Firebase Analytics discards data that is generally >72 hours old Measurement tools (Perf, Analytics, Crashlytics) are suspicious of data that looks too old - Todd Kerpelman @ Firebase Summit 2019 Notably, this 72hr limit is not a hard limit like the cache size and event limits are, so there are times where more than 72hrs can be cached offline and reported back to the servers though this is not guaranteed. Summary of Perf, Analytics, Crashlytics in above video: Performance Monitoring Android: 10MB cache across all apps iOS: 10MB cache across each app
Recommends Frank van Puffelen · 2021-06 · Stack Overflow · on “Offline mirror for Firebase”
The Firebase Emulator Suite is for development, not sure production use. From its documentation [LINK] : The Firebase Local Emulator Suite is a set of advanced tools for developers looking to build and test apps locally So it is (currently at least) not suitable for using in the scenario you describe. What you can do is look at the offline mode of the various Firebase products, to see if they fit your needs. I recommend checking the documentation for each, or this handy video that covers all of them: Firebase offline: What works, what doesn't, and what you need to know [this video] .
Recommends Frank van Puffelen · 2025-01 · Stack Overflow · on “How can I manage write to Firestore and Cloud Storage while offline?”
As you discovered: the Firestore SDK caches offline writes locally immediately, but only resolves the Future it returns once the write is committed on the server (hence needing to remove await ). Removing the await means that you don't want the local client to wait until the remote write is completed, which seems to be exactly the offline behavior you want. No such offline support exists in the Firebase SDK for Cloud Storage however. If there is no connection, the upload simply times out and/or fails (depending on config and system). To allow the user to schedule an upload while they're offline, you'll have to implement such scheduling yourself. So: Detect that the user is offline Write the
Cites d3raymon · 2020-12 · Stack Overflow · on “Saving to Cloud Firestore on iOS hangs when offline”
This is the expected behaviour - you should assume that the write will happen when the device comes back online. In my use cases, I've just continued with the normal flow and used my local data as my source of truth. It's mentioned here: [this video]