Turn new Firebase documents into Google Sheet rows

Every time a new record lands in your Firebase database, we add a clean, readable row to a Google Sheet so your whole team can follow along without touching the database.

Deterministic Code
FirebaseGoogle SheetsOperationsEngineeringData Sync
PromptCreate

This is a deterministic logging pipeline. Use a Firebase poll trigger that fires whenever a new document is created in a specific Firestore collection (new_document). Firestore is the source of truth and a Google Sheet is the running, human-readable log, so non-technical teammates can see every new record without ever touching the database.

For each new document, capture the document id, its created timestamp (formatted as an ISO 8601 string), and a fixed, predefined set of fields. If the trigger payload does not already include the full document body, use Firebase Get Firestore Document to fetch it by its path before building the row.

Firestore wraps every field in a typed value envelope (stringValue, integerValue, doubleValue, booleanValue, timestampValue, mapValue, arrayValue, and so on). Flatten these into plain cell values: unwrap scalars to their raw value, render timestamps as ISO 8601, and serialize nested maps and arrays into compact, readable text so the spreadsheet stays clean. Keep a stable column order across every run so each column always means the same thing.

Append the resulting row to the Google Sheet using Google Sheets Append Values, writing one row per new document to a fixed range so rows accumulate as an append-only log. Never modify or delete existing rows, and never write back to Firestore.

Keep the mapping fully deterministic: the same document always produces the same row in the same column order. If a captured field is missing on a given document, write an empty cell for that column rather than shifting the other values, so the columns stay aligned.

Additional information

What does this prompt do?
  • Watches a Firebase collection and adds a new spreadsheet row the moment a record is created
  • Captures each record's ID, its created time, and the fields you choose, always in the same column order
  • Flattens nested or complex data into plain, readable cells so the sheet stays tidy
  • Gives non-technical teammates a live log of new records without ever opening the database
What do I need to use this?
  • A Firebase project with a Firestore collection you want to track
  • A Google account and a Google Sheet to log the rows into
  • The list of fields you want each row to capture
How can I customize it?
  • Choose which Firebase collection to watch and which fields become columns
  • Set the column order and add a header row that matches your team's naming
  • Point it at a different tab or spreadsheet as your log grows

Frequently asked questions

Does this change anything in my Firebase database?
No. It only reads new records and writes them to your Google Sheet. Your Firebase data is never edited or deleted.
What happens to nested or complex fields?
They are flattened into plain, readable text so each cell stays simple and the spreadsheet stays clean, instead of dumping raw database formatting.
Will my existing records get added too?
No. This logs new records going forward, adding one row each time a fresh document is created in your collection.
Can non-technical teammates use the sheet?
Yes, that is the whole point. Everyone gets a live, readable log in a familiar spreadsheet without needing any database access.
How soon does a new row show up?
Shortly after the record is created. The workflow checks your collection for new documents on a regular schedule and appends a row for each one.

Give your team a live log of every new record.

Set up automatic logging from Firebase to Google Sheets in a couple of clicks.