google_cloud_firestore
0.5.5, released 2 months ago by firebase.google.com
A Dart client library for Google Cloud Firestore database.
What it does
Provides a complete API for interacting with Google Cloud Firestore, including documents, collections, queries, transactions, batches, and bulk writes. It can be used standalone or with the Firebase Admin SDK.
AI-written summary of version 0.5.5, based on the package's README and metadata. Report an inaccuracy
Use it when
- You are building a backend or server application in Dart that needs to interact with Google Cloud Firestore.
- You are running inside Firebase Functions or using the Firebase Admin SDK and need Firestore access.
Skip it when
- You are building a mobile client application using standard Firebase mobile SDKs (use cloud_firestore instead).
Strengths
- Complete API support for documents, collections, queries, transactions, and enterprise pipeline operations.
- Supports connection pooling via HTTP/2 and integrates with Application Default Credentials or service accounts.
Weaknesses
- Not intended as a direct drop-in replacement for the mobile client-side cloud_firestore package.
Setup
- Kind
- Pure Dart
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 12
Requires either Application Default Credentials (e.g., via gcloud auth application-default login or environment variables) or a service account JSON file.
import 'package:google_cloud_firestore/google_cloud_firestore.dart';
final firestore = Firestore();
final ref = firestore.collection('users').doc('user-id');
await ref.set({'name': 'John Doe', 'age': 27});Alternatives
Packages that do the same job and could replace google_cloud_firestore.
- cloud_firestore
Choose cloud_firestore if you are building a client mobile/web app using Firebase plugins rather than server-side or Cloud/Admin integration.
98Compare
Works with
Packages commonly used together with google_cloud_firestore: ones it builds on, ones built on it, and its own family.
- intlgoogle_cloud_firestore depends on itA Dart library for internationalization and localization, providing message translation, plural/gender handling, and date/number formatting.
- retrygoogle_cloud_firestore depends on itProvides automatic retry with exponential back‑off for async functions.
- googleapis_authgoogle_cloud_firestore depends on itObtain Access credentials and authenticated HTTP clients for Google APIs using OAuth 2.0.
- google_cloudgoogle_cloud_firestore depends on itUtilities for running Dart code correctly on the Google Cloud Platform.
- http2google_cloud_firestore depends on itAn HTTP/2 implementation in Dart for low-level transport and pooled HTTP/2 requests.
- firebase_admin_sdkBuilt on google_cloud_firestoreFirebase Admin SDK implementation for Dart server environments
- firebase_functionsBuilt on google_cloud_firestoreDefine Cloud Functions for Firebase in Dart with support for the Admin SDK and Firestore.