Google Cloud Firestore
Last updated
Was this helpful?
Last updated
Was this helpful?
Google Firebase is a set of services and hosting tools for creating serverless applications (be it web or mobile) including a real-time NoSQL database as a service, services for authentication, storing files, various analytics, and serverless functions (private business logic). It removes the need to deploy and maintain one or multiple servers for these types of features, thus letting the focus be on the client application rather than also dealing with scaling, securing, and keeping the latest software for a server.
It is a very popular, cost-effective (free of charge for low usage) method to start a real-life web or mobile product. You can find more at:
Cloud Firestore is a NoSQL, document-oriented database as a service. You store data in JSON documents, which are organized into collections.
Each document contains a set of key-value pairs. Cloud Firestore is optimized for storing large collections of small documents.
All documents must be stored in collections. Documents can contain subcollections and nested objects, both of which can include primitive fields like strings or complex objects like lists.
Then, you'll need to create a project which will have access to the tools provided by the Firebase suite. For this project, you have to create a database. The option is available in the project's menu and doesn't require any sort of setup.
Access to a Firestore database, in a Node.js app is done through an admin SDK which is installed by running the following command:
npm install firebase-admin --save
To use the Firebase Admin SDK on your own server (or any other Node.js environment), use a service account. Go to IAM & admin > Service accounts in the Cloud Platform Console. Generate a new private key and save the JSON file. Then use the file to initialize the SDK:
The credentials are generated from the Google Firebase Console, in the settings section of a project, at the Service Accounts tab.
The JSON file should look like this:
As an alternative, you can also read about:
or less popular (this is an SQL DB as a service)
First of all, you need to set up a Google Firebase account at: