Back to Integrations
integrationNotion node
integrationSupabase node

Notion and Supabase integration

Save yourself the work of writing custom integrations for Notion and Supabase and use n8n instead. Build adaptable and scalable Productivity, and Data & Storage workflows that work with your technology stack. All within a building experience you will love.

How to connect Notion and Supabase

  • Step 1: Create a new workflow
  • Step 2: Add and configure nodes
  • Step 3: Connect
  • Step 4: Customize and extend your integration
  • Step 5: Test and activate your workflow

Step 1: Create a new workflow and add the first step

In n8n, click the "Add workflow" button in the Workflows tab to create a new workflow. Add the starting point – a trigger on when your workflow should run: an app event, a schedule, a webhook call, another workflow, an AI chat, or a manual trigger. Sometimes, the HTTP Request node might already serve as your starting point.

Notion and Supabase integration: Create a new workflow and add the first step

Step 2: Add and configure Notion and Supabase nodes

You can find Notion and Supabase in the nodes panel. Drag them onto your workflow canvas, selecting their actions. Click each node, choose a credential, and authenticate to grant n8n access. Configure Notion and Supabase nodes one by one: input data on the left, parameters in the middle, and output data on the right.

Notion and Supabase integration: Add and configure Notion and Supabase nodes

Step 3: Connect Notion and Supabase

A connection establishes a link between Notion and Supabase (or vice versa) to route data through the workflow. Data flows from the output of one node to the input of another. You can have single or multiple connections for each node.

Notion and Supabase integration: Connect Notion and Supabase

Step 4: Customize and extend your Notion and Supabase integration

Use n8n's core nodes such as If, Split Out, Merge, and others to transform and manipulate data. Write custom JavaScript or Python in the Code node and run it as a step in your workflow. Connect Notion and Supabase with any of n8n’s 1000+ integrations, and incorporate advanced AI logic into your workflows.

Notion and Supabase integration: Customize and extend your Notion and Supabase integration

Step 5: Test and activate your Notion and Supabase workflow

Save and run the workflow to see if everything works as expected. Based on your configuration, data should flow from Notion to Supabase or vice versa. Easily debug your workflow: you can check past executions to isolate and fix the mistake. Once you've tested everything, make sure to save your workflow and activate it.

Notion and Supabase integration: Test and activate your Notion and Supabase workflow

Provide Real-Time Updates for Notion Databases via Webhooks with Supabase

Purpose

This enables webhooks for nearly realtime updates (every 5 seconds) from Notion Databases.

Problem

Notion does not offer webhooks. Even worse, the “Last edited time” property, we could use for polling, only updates every minute. This gives us a polling interval only as low as 2 minutes and we still need to implement a comparing mechanism to detect changes.

Solution

This workflow caches states in between while doing efficient polling & comparing. It brings down the update latency from 2 minutes to 5 seconds and also provides the output of the changes only.

Demo

Get real-time updates from Notion Databases

How it works

  • Database Pages are frequently polled while filtered by a last modified time stamp for more efficiency
  • Retrieved pages get compared with previously cached versions in Supabase
  • Only new and changed pages are pushed to a registered webhook

Setup

  • Create a new project in Supabase and import the DB schema (provided through Gumroad)
  • Add a "Last edited time" property to your Notion Database, if it has none yet
  • Define the dynamically generated settings_id from the settings table (Supabase) in the Globals node
  • Define the Notion Database URL in the Globals node
  • Define your custom Webhook URL in the last node where the results should be pushed to
  • It is recommended to call this workflow using this template to prevent simultaneous workflow executions
  • Set the Schedule Trigger to every 5 seconds or less frequent
  • More detailed instructions provided within the workflow file and the illustrated instructions provided during the download

Example output

[
  {
    "action": "changed",
    "changes": {
      "property_modified_at": "2024-06-04T17:59:00.000Z",
      "property_priority": "important"
    },
    "data": {
      "id": "ba761e03-7d6d-44c2-8e8d-c8a4fb930d0f",
      "name": "Try out n8n",
      "url": "https://www.notion.so/Try-out-n8n-ba761e037d6d44c28e8dc8a4fb930d0f",
      "property_todoist_id": "",
      "property_id": "ba761e037d6d44c28e8dc8a4fb930d0f",
      "property_modified_at": "2024-06-04T17:59:00.000Z",
      "property_status": "Backlog",
      "property_priority": "important",
      "property_due": {
        "start": "2024-06-05",
        "end": null,
        "time_zone": null
      },
      "property_focus": false,
      "property_name": "Try out n8n"
    },
    "updated_at": "2024-06-04T17:59:42.144+00:00"
  }
]

Nodes used in this workflow

Popular Notion and Supabase workflows

Notion node
Supabase node
Code node
+5

Provide Real-Time Updates for Notion Databases via Webhooks with Supabase

Purpose This enables webhooks for nearly realtime updates (every 5 seconds) from Notion Databases. Problem Notion does not offer webhooks. Even worse, the “Last edited time” property, we could use for polling, only updates every minute. This gives us a polling interval only as low as 2 minutes and we still need to implement a comparing mechanism to detect changes. Solution This workflow caches states in between while doing efficient polling & comparing. It brings down the update latency from 2 minutes to 5 seconds and also provides the output of the changes only. Demo How it works Database Pages are frequently polled while filtered by a last modified time stamp for more efficiency Retrieved pages get compared with previously cached versions in Supabase Only new and changed pages are pushed to a registered webhook Setup Create a new project in Supabase and import the DB schema (provided through Gumroad) Add a "Last edited time" property to your Notion Database, if it has none yet Define the dynamically generated settings_id from the settings table (Supabase) in the Globals node Define the Notion Database URL in the Globals node Define your custom Webhook URL in the last node where the results should be pushed to It is recommended to call this workflow using this template to prevent simultaneous workflow executions Set the Schedule Trigger to every 5 seconds or less frequent More detailed instructions provided within the workflow file and the illustrated instructions provided during the download Example output [ { "action": "changed", "changes": { "property_modified_at": "2024-06-04T17:59:00.000Z", "property_priority": "important" }, "data": { "id": "ba761e03-7d6d-44c2-8e8d-c8a4fb930d0f", "name": "Try out n8n", "url": "https://www.notion.so/Try-out-n8n-ba761e037d6d44c28e8dc8a4fb930d0f", "property_todoist_id": "", "property_id": "ba761e037d6d44c28e8dc8a4fb930d0f", "property_modified_at": "2024-06-04T17:59:00.000Z", "property_status": "Backlog", "property_priority": "important", "property_due": { "start": "2024-06-05", "end": null, "time_zone": null }, "property_focus": false, "property_name": "Try out n8n" }, "updated_at": "2024-06-04T17:59:42.144+00:00" } ]

Build your own Notion and Supabase integration

Create custom Notion and Supabase workflows by choosing triggers and actions. Nodes come with global operations and settings, as well as app-specific parameters that can be configured. You can also use the HTTP Request node to query data from any app or service with a REST API.

Notion supported actions

Append After
Append a block
Get Child Blocks
Get many child blocks
Get
Get a database
Get Many
Get many databases
Search
Search databases using text search
Get
Get a database
Get Many
Get many databases
Create
Create a pages in a database
Get
Get a page in a database
Get Many
Get many pages in a database
Update
Update pages in a database
Create
Create a pages in a database
Get Many
Get many pages in a database
Update
Update pages in a database
Create
Create a page
Get
Get a page
Search
Text search of pages
Archive
Archive a page
Create
Create a page
Search
Text search of pages
Get
Get a user
Get Many
Get many users

Supabase supported actions

Create
Create a new row
Delete
Delete a row
Get
Get a row
Get Many
Get many rows
Update
Update a row

FAQs

  • Can Notion connect with Supabase?

  • Can I use Notion’s API with n8n?

  • Can I use Supabase’s API with n8n?

  • Is n8n secure for integrating Notion and Supabase?

  • How to get started with Notion and Supabase integration in n8n.io?

Looking to integrate Notion and Supabase in your company?

Over 3000 companies switch to n8n every single week

Why use n8n to integrate Notion with Supabase

Build complex workflows, really fast

Build complex workflows, really fast

Handle branching, merging and iteration easily.
Pause your workflow to wait for external events.

Code when you need it, UI when you don't

Simple debugging

Your data is displayed alongside your settings, making edge cases easy to track down.

Use templates to get started fast

Use 1000+ workflow templates available from our core team and our community.

Reuse your work

Copy and paste, easily import and export workflows.

Implement complex processes faster with n8n

red iconyellow iconred iconyellow icon