Mobile — Databases & Storage
SQLite, Room, GRDB, SwiftData, MMKV, Realm, WatermelonDB, Drift — local-first storage choices.
Local storage on mobile is mostly SQLite under different wrappers, with key-value stores as the small/fast tier and a handful of object/NoSQL options. For sync engines see PWA and realtime. For server-side databases see databases-orms.
iOS / Swift
- ★ SwiftData — Apple's Core Data successor (iOS 17+). Macros + Core Data backend; CloudKit sync built-in. The default for new SwiftUI apps.
- Core Data — still the longest-running iOS persistence; not deprecated.
- ★ GRDB — best-in-class SQLite library; reactive (
ValueObservation); type-safe; excellent docs. MIT. - SQLite.swift — simpler SQLite wrapper.
- Realm — MongoDB-owned object DB; free SDK; Atlas Sync paid.
- Defaults (sindresorhus) — type-safe
UserDefaultswrapper. - KeychainAccess — Keychain wrapper for secrets.
Android / Kotlin
- ★ Room (Jetpack) — SQLite ORM; the default. Multiplatform support added in Room 2.7.
- ★ DataStore (Jetpack) — replaces SharedPreferences for typed prefs.
- SQLDelight — type-safe SQL across KMP; the default for KMP apps. Apache 2.0.
- Realm Kotlin — KMP-supported.
- ObjectBox — fast NoSQL; free + paid sync.
- MMKV (Tencent) — fast KV; cross-platform; faster than DataStore for hot paths. BSD.
React Native
- ★ op-sqlite — fast SQLite for RN; New-Arch friendly.
- expo-sqlite — Expo's official; great for most.
- react-native-quick-sqlite — older fast bindings; superseded by op-sqlite for many.
- Drizzle +
expo-sqlite— typed local DB. - ★ MMKV (
react-native-mmkv) — fast KV; replaces AsyncStorage. - AsyncStorage — built-in; slow.
- react-native-keychain — secure storage.
- WatermelonDB — local-first reactive DB; sync-able.
Flutter
- ★ Drift — typed SQLite ORM; reactive queries; the recommended default.
- sqflite — bare SQLite plugin; minimal.
- Isar — fast NoSQL; check current maintenance.
- Hive / hive_ce — KV store;
hive_ceis the maintained fork. - shared_preferences — small typed prefs.
- flutter_secure_storage — Keychain / Keystore wrapper.
KMP / Compose Multiplatform
- ★ SQLDelight — multiplatform type-safe SQL.
- Room 2.7+ — KMP-capable.
- Realm Kotlin — KMP.
- multiplatform-settings — small KV across platforms.
- Store5 — caching / repository layer.
Sync engines (local-first)
- WatermelonDB — RN; can sync to your backend.
- PowerSync — Postgres ↔ SQLite sync; iOS / Android / RN / Flutter.
- ElectricSQL — Postgres ↔ SQLite sync.
- Triplit, InstantDB — full sync stacks.
- CouchBase Lite + Sync Gateway — paid + open-source pieces.
- Yjs / Automerge — CRDT-shaped multi-user sync.
Secure / encrypted storage
- ★ iOS Keychain — built-in secure storage; access via
Security.frameworkor wrappers (KeychainAccess). - ★ Android Keystore — hardware-backed key storage.
- react-native-keychain, expo-secure-store, flutter_secure_storage — wrappers.
- MMKV with encryption — opt-in AES.
File storage
- iOS —
FileManager, App Group containers, iCloud Documents. - Android — Scoped Storage (Android 11+), MediaStore, app-specific folders.
- expo-file-system, react-native-fs, path_provider (Flutter).
Pick this if…
- iOS-only, new app: SwiftData; reach for GRDB if you outgrow it.
- Android-only, new app: Room + DataStore + MMKV for hot paths.
- RN: op-sqlite or expo-sqlite + Drizzle for typed access; MMKV for KV.
- Flutter: Drift + flutter_secure_storage + shared_preferences.
- KMP shared persistence: SQLDelight or Room 2.7.
- Local-first multi-device sync: PowerSync / ElectricSQL or WatermelonDB.
- CRDT collaborative: Yjs or Automerge — link to realtime.