- Home
- Resources
- Integrations
- Google Cloud Firestore
Google Cloud Firestore n8n integrationAutomate Google Cloud Firestore with n8n.
Where does a workflow put the records it just processed? The Google Cloud Firestore n8n integration answers that with 7 operations spread over 2 resources: write, read, query and delete documents, and list root collections. No trigger node here, so the workflow starts somewhere else.
Verified Trustpilot reviews · AI, automation & growth agency
What does the Google Cloud Firestore n8n integration do?
Google Cloud Firestore is Google's document database, and the n8n node talks to it directly: 7 operations across 2 resources, Document and Collection. You create, read, update and delete documents, list the root collections of a database, or send a raw structured query, without writing client code.
Firestore has no trigger node in n8n, so a workflow starts from something else: a Schedule Trigger that fires at a fixed interval, an n8n Webhook (a URL another service calls), or the trigger of another app.
Take a signup flow. A form or an app posts to an n8n Webhook, a Code node cleans the payload, and document.upsert writes it to a users collection keyed by the signup id. Run the same workflow twice on the same person and you still have one document, because upsert updates instead of duplicating. A Slack message at the end tells the team a new account landed.
Second scenario, the nightly export. A Schedule Trigger wakes the workflow, document.getAll pulls a collection with Return All enabled, and the items go to Google Sheets for the people who live in spreadsheets. Swap the destination for Postgres or Supabase when the data has to land in SQL for reporting.
Third, a lookup inside a bigger automation. Someone replies to an email, the workflow needs the customer record, and document.get returns it by id. When the id is unknown, document.query takes a structured query in JSON and filters on a field instead.
Reach for the HTTP Request node when the operation is not in this list. It calls any Firestore endpoint and reuses the same credential through predefined authentication, so nothing extra to set up. Batch writes, index management or anything the node does not expose goes there.
Two limits worth knowing before you build. There is no event stream: a document changed in Firestore will not wake n8n by itself, polling on a schedule is the way. And document.query expects raw structured query JSON, not a friendly filter builder, so keep the Firestore query syntax at hand. If you want a guided tour of the whole builder, the n8n training covers it.
How do you connect Firestore to n8n?
- 01
Create the credential in n8n
Open the Credentials menu and pick the Google Cloud Firestore OAuth2 credential (
googleFirebaseCloudFirestoreOAuth2Api). A credential is stored once and reused by every workflow, and the node offers it in a dropdown. On n8n Cloud, Managed OAuth2 is the short path: click Sign in with Google and nothing else is needed in the Google Cloud Console. - 02
Build the OAuth client in Google Cloud Console
Self-hosted instances go through Custom OAuth2. Create a Google Cloud project, enable the APIs, then configure the OAuth consent screen with an App name and a User support email. Under Branding, add
n8n.cloudas an authorized domain, or your own instance domain. Then go to Credentials, Create credentials, OAuth client ID, application type Web application, and paste the OAuth Redirect URL from your n8n credential into Authorized redirect URIs. - 03
Or authenticate with a service account
The node also accepts a Service Account credential (
serviceAccount), useful when no human should sit in the OAuth flow. In the console: Credentials, Create credentials, Service account, fill Service account name and Service account ID, then open the Keys tab and choose Add key, Create new key, JSON. Open the downloaded file, copyclient_emailinto Service Account Email andprivate_keyinto Private Key, without the surrounding quote marks.
The 7 operations of the Firestore node
The Google Cloud Firestore node exposes 7 operations across 2 resources. For each one: the node as you configure it in n8n, the required fields, and our field notes.
| Resource | Create | Get | Get Many | Delete | Query | Create or Update |
|---|---|---|---|---|---|---|
| Document | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
| Collection | ✓ |
Operations index
Document
6 operationsCreate a document
document.createWhat you see in n8n
Notes & use cases
Writes a new document into a collection and returns what Firestore stored. Each listed attribute becomes a field.
Key parameters
- Project Name or ID: the project as displayed in the firebase console URL, from the list or from an expression, the n8n syntax that reads a field of the incoming item (
{{ $json.projectId }}). - Database: the database to write to, usually the provided default value.
- Collection: the collection that receives the document.
- Columns / Attributes: the attributes to save, for example
productId, modelName, description. - Document ID: optional. Empty, Firestore generates an id; filled, it keeps your own key.
Create or update a document
document.upsertWhat you see in n8n
Notes & use cases
One call covers both cases: the document is created when it does not exist, updated when it does. A workflow that runs twice on the same record leaves one document, not two.
Key parameters
- Project Name or ID: same project picker as the other operations.
- Database: the target database, usually the provided default value.
- Collection: the collection holding the documents to upsert.
- Update Key: the field of the input item that carries the document ID,
documentIdfor instance. It decides create against update. - Columns /Attributes: the columns to insert, such as
age, city, location.
Delete a document
document.deleteWhat you see in n8n
Notes & use cases
Removes one document from a collection. Firestore deletes by path, so the operation needs the exact id, not the value of a field inside the document.
Key parameters
- Project Name or ID: the Firestore project, chosen in the list or built from an expression.
- Database: the database that holds the collection.
- Collection: the collection name.
- Document ID: the id of the document to remove, often
{{ $json.documentId }}from an earlier node.
Get a document
document.getWhat you see in n8n
Notes & use cases
Reads a single document back and hands its fields to the next node. Nothing is written, which makes it the safe way to check a record before acting on it.
Key parameters
- Project Name or ID: the project shown in the firebase console URL.
- Database: the database to read from.
- Collection: the collection to look into.
- Document ID: the id to fetch. A required field blocks the node when it comes in empty, so guard it with an If node.
- Simplify: on, n8n returns a flat version of the document instead of the raw typed payload.
Get many documents
document.getAllWhat you see in n8n
Notes & use cases
Pulls the documents of one collection as a list of items, one item per document, ready for a loop or an export.
Key parameters
- Project Name or ID: the Firestore project.
- Database: the database that contains the collection.
- Collection: the collection to read.
- Return All: on, n8n walks the API pages until every document of the collection is in. Off, it stops at Limit.
- Limit: the maximum number of documents returned when Return All stays off.
- Simplify: returns the documents in their simplified shape rather than the raw response.
Query a document
document.queryWhat you see in n8n
Notes & use cases
Runs a query against your documents and returns the ones that match, which beats fetching a whole collection and filtering it in a Code node.
Key parameters
- Project Name or ID: the project the query runs against.
- Database: the database holding the data.
- Query JSON: the query to execute, in Firestore structured query syntax, for example
{"structuredQuery": {"where": {"fieldFilter": {"field": {"fieldPath": "age"},"op": "EQUAL", "value": {"integerValue": 28}}}, "from": [{"collectionId": "users-collection"}]}}. The collection is named inside the query itself, not in a separate field. - Simplify: trims the response to the document fields.
Collection
1 operationGet many collections
collection.getAllWhat you see in n8n
Notes & use cases
Lists the root collections of a database, so a workflow can discover what exists instead of hardcoding collection names.
Key parameters
- Project Name or ID: the project whose collections you want.
- Database: the database to inspect, usually the provided default value.
- Return All: on, every root collection comes back. Off, the node stops at Limit.
- Limit: how many collections to return when Return All is off.
Need help automating Google Cloud Firestore with n8n?
A person reads every message.
Google Cloud Firestore and n8n, common questions
01Is the Google Cloud Firestore n8n integration free?
02What credentials does the Firestore node need?
03What are the limits of the Firestore node?
04Can n8n react to a change in Firestore in real time?
05n8n or Make for Google Cloud Firestore?
Get our weekly integration tips.
No spam. Unsubscribe anytime.



