Firestore is Google Cloud's fully managed, serverless, document-oriented NoSQL database. It is the successor to the original Cloud Datastore and is designed for building web, mobile, and server applications that need real-time synchronisation, offline support, and automatic scaling to zero.
What Is Firestore?
Firestore is a flexible, scalable NoSQL document database that provides:
Document-collection model — data is organised into collections of documents, each containing key-value pairs.
Real-time listeners — clients receive instant updates when data changes.
Offline support — SDKs cache data locally, enabling offline reads and writes that sync when connectivity returns.
Serverless — no instances to manage; scales automatically from zero to millions of operations.
ACID transactions — multi-document transactions across collections.
Strong consistency — all reads return the latest committed data.
Data Model
Documents and Collections
A document is a set of key-value pairs (similar to a JSON object). Each document has a unique ID within its collection.
A collection is a container for documents. Collections can only contain documents (no nested collections directly — but documents can contain subcollections).
Example
Subscribe to continue reading
Get full access to this lesson and all 10 lessons in this course.