DEV Community

Cover image for Why Google thought of creating Cloud Firestore even when they had Realtime Database.
Sumrit Grover
Sumrit Grover

Posted on

Why Google thought of creating Cloud Firestore even when they had Realtime Database.

Google Firebase provides two kinds of cloud-based client-accessible database solutions for mobile apps that allow realtime data synchronization –
Realtime Database and Cloud Firestore.

Realtime Database

Realtime Database is Firebase's original and first cloud-based database.

It is an efficient and low-latency solution for mobile apps that require synchronised states among clients in realtime.

Realtime Database icon

Cloud Firestore

Cloud Firestore is the newest flagship database for mobile apps from Firebase. It is the Realtime Database's successor, with a new and more intuitive data model.

Cloud Firestore is more powerful, quicker, more scalable than Realtime Database.

Cloud Firestore icon

Which one should you choose?

  • Realtime Database and Cloud Firestore, both are NoSQL Databases.

  • Data is stored in Realtime Database as a single huge JSON tree, making it easier to store simple data but more difficult to arrange complicated, hierarchical data at scale.

-Cloud Firestore organizes data into groupings of documents. Subcollections within documents make it easy to arrange complex, hierarchical data at scale. Cloud Firestore requires less data flattening and denormalization.

Through queries, data may be accessed, sorted, and filtered from any of the databases.

-Deep queries are supported by Realtime Database, but only with restricted sorting and filtering options.

-Cloud Firestore supports indexed queries with compound sorting and filtering.

API Trace View

How I Cut 22.3 Seconds Off an API Call with Sentry

Struggling with slow API calls? Dan Mindru walks through how he used Sentry's new Trace View feature to shave off 22.3 seconds from an API call.

Get a practical walkthrough of how to identify bottlenecks, split tasks into multiple parallel tasks, identify slow AI model calls, and more.

Read more →

Top comments (0)

AWS Security LIVE!

Join us for AWS Security LIVE!

Discover the future of cloud security. Tune in live for trends, tips, and solutions from AWS and AWS Partners.

Learn More

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay