How to Sync Google Sheets Data with Notion Databases via n8n

Learning how to sync Google Sheets Notion n8n pipelines eliminates hours of manual copy-pasting and prevents stale records across your workspace. While native connectors often charge per-task fees or choke on complex property mappings, a self-hosted or cloud n8n instance gives you deterministic control over row-level deduplication, batch processing, and API rate limits.

In this technical guide, you will build a production-grade workflow that reads rows from Google Sheets, filters out already-synced records using a unique identifier, maps data types accurately, and pushes updates directly into a structured Notion database—complete with a copy-pasteable JSON blueprint.

⚡ Workflow Architecture at a Glance

Trigger (Schedule / Sheet Update) → Google Sheets (Get Rows) → Notion (Query Existing IDs) → Merge / Filter (Upsert Routing) → Split in Batches + Wait (Rate-Limit Safe) → Notion (Create or Update Database Page).

Video Walkthrough: Connecting Notion & Google Sheets in n8n

Prefer watching the node configuration live before importing the JSON template? The walkthrough below covers generating your Notion Internal Integration Secret, granting page-level access, and building the core Google Sheets-to-Notion pipeline (jump to 16:56 for the Sheets workflow):

Prerequisites

Before configuring your nodes, ensure the following requirements are in place:

  • Active n8n Instance: Either n8n Cloud or a self-hosted Docker deployment running v1.70+ (for modern Notion and Google Sheets v4 nodes).
  • Google Cloud OAuth2 Credentials: Google Sheets API and Google Drive API enabled in your Google Cloud Console, linked inside n8n Credentials.
  • Notion Workspace Admin Access: Required to create an Internal Integration and authorize database access.
  • A Primary Key Column: Both your Google Sheet and Notion Database must share one unique identifier column (e.g., Record_ID, SKU, or Email) to prevent duplicate rows on subsequent runs.

Step-by-Step Blueprint: Sync Google Sheets Data with Notion

Step 1: Generate a Notion Internal Integration & Grant Database Access

Unlike standard OAuth apps, Notion requires explicit per-page authorization even after you generate an API secret. Skipping the second half of this step is the #1 reason n8n returns an empty database list.

  1. Navigate to Notion Settings → Connections → Develop or manage integrations and click New integration.
  2. Name it n8n-sync-bot, select your target workspace, and set the type to Internal.
  3. Under Capabilities, ensure Read content, Update content, and Insert content are checked, then copy the Internal Integration Secret (starts with ntn_ or secret_).
  4. Open your target Notion database page, click the ••• (three-dot menu) in the top-right corner, select Connections → Connect to, and choose n8n-sync-bot.

Step 2: Structure Your Google Sheet & Notion Database Schema

Aligning column names and data types upfront saves heavy transformation expressions later. Note the crucial architectural distinction in Notion: writing structured rows requires the Database Page resource, whereas Append a Block only injects unstructured text inside a page body.

Google Sheets Column Notion Property Type n8n Mapping & Expression Note
Record_ID Rich Text (or Number) Primary deduplication key used to match existing rows.
Task_Name Title Every Notion database requires exactly one Title field.
Status Status / Select String must match an existing Notion option or auto-create must be allowed.
Tags (comma-separated) Multi-select Split string into array: {{ $json.Tags.split(',').map(t => t.trim()) }}
Due_Date Date Must evaluate to ISO 8601 format (YYYY-MM-DD).

Step 3: Configure the Trigger & Google Sheets Reader Node

You have two trigger options depending on your latency needs:

  • Google Sheets Trigger (On Row Added or Updated): Polls your spreadsheet at a defined interval (every minute, hour, or day) and emits only changed rows.
  • Schedule Trigger + Google Sheets (Get Many Rows): Better for full-table reconciliation. Select your spreadsheet by ID (the string between /d/ and /edit in your sheet URL) and specify the target tab name.

Attach an Edit Fields (Set) node immediately after Google Sheets to strip unused columns, cast numeric strings to actual numbers, and normalize empty cells so Notion doesn't throw validation errors.

Step 4: Implement Upsert Logic (Preventing Duplicate Notion Entries)

Because n8n's native Notion node does not offer a single-click "Create or Update" operation like the Google Sheets node, you should build a clean two-branch upsert check:

  1. Add a Notion Node configured with Resource: Database Page and Operation: Get Many (enable Return All) to fetch existing records and their internal Notion page_id values.
  2. Connect both your Google Sheets stream (Input 1) and your Notion Get Many stream (Input 2) into a Merge Node set to Combine → Match By Fields on Record_ID.
  3. Use an IF Node to check whether {{ $json.id }} (the Notion Page ID) exists:
    • True Branch (Record Exists): Route to Notion → Database Page → Update using {{ $json.id }} as the Page ID.
    • False Branch (New Record): Route to Notion → Database Page → Create and map your sheet columns to Notion properties.

Step 5: Handle Notion API Rate Limits with Batching

Notion enforces an average rate limit of 3 requests per second per integration. If you sync 200 rows simultaneously, n8n will hit 429 Too Many Requests errors. Wrap your Notion Create/Update node inside a Loop Over Items (Split in Batches) node with Batch Size = 1, followed by a Wait Node set to 0.4 seconds before looping back.

💡 Production Pro-Tip: Two-Way Sync Loop Prevention

If you later add a reverse workflow (Notion → Google Sheets), add a Last_Synced_By metadata column. Have n8n tag its own writes as n8n_bot and add a Filter Node at the start of both workflows to ignore updates triggered by n8n_bot—otherwise, both workflows will trigger each other in an infinite loop.

Copy-Paste n8n Workflow JSON Template

Copy the JSON snippet below, open your n8n canvas, and press Ctrl + V (or Cmd + V on macOS) to import the complete Google Sheets → Filter → Batch Loop → Notion pipeline. Replace the placeholder credential IDs and Database/Sheet IDs with your own.

Troubleshooting & Common Errors

1. Error: "Could not find database with ID" (404 Object Not Found)

Cause: Your Notion Internal Integration exists, but you have not explicitly invited it to the target database page.
Fix: Open the database in Notion → click ••• (top right) → Connections → add your integration. If the database sits inside a parent page, granting access to the parent page cascades permissions to all child databases automatically.

2. Error: "body failed validation: body.properties... expected to be object/array"

Cause: Passing a raw comma-separated string from Google Sheets into a Notion Multi-select or Relation property.
Fix: Transform the string into a clean JavaScript array inside an expression: {{ $json.Tags ? $json.Tags.split(',').map(item => item.trim()) : [] }}.

3. Error: Google Sheets Row Numbers Offset by 1

Cause: n8n treats Row 1 as the schema header, meaning your first actual data record begins at row_number: 2.
Fix: Never hardcode array indices when updating rows back in Google Sheets. Always use the Update Row operation matched by your unique Record_ID column.

Post a Comment for "How to Sync Google Sheets Data with Notion Databases via n8n"