Skip to content

Updating visuals

If you see any images containing outdated UI, please bear with us.

We are updating all content as quickly as possible to mirror our new UI.

Supabase integration

Supabase is a platform for storing data, managing sign in, hosting files, and running server logic. The Supabase integration lets you connect your Supabase project to WeWeb so you can use it as a data source and call Supabase features from workflows.

What this integration supports

Once connected, you can:

  • Create WeWeb tables that use a Supabase table as the data source.
  • Read and update Supabase rows in workflows.
  • Upload and retrieve files from Supabase Storage.
  • Call Supabase Edge Functions and Postgres functions.
  • Use Supabase Auth actions (sign up, sign in, sign out, and OAuth sign in).

WHERE YOU CAN USE SUPABASE ACTIONS

Most Supabase actions are available in both places:

  • In Database & APIs workflows (API Endpoints).
  • In Interface workflows (for example when a user clicks a button).

This gives you a choice:

  • Use an Interface workflow when you want a quick action that happens directly from the app (for example upload a profile picture).
  • Use an API Endpoint when you want the safest setup for access control and data rules (recommended for anything sensitive).

Supabase Auth actions like Login, Sign Up, and Login with Provider are only available in Interface workflows.

Setup in Supabase

Before connecting Supabase to WeWeb, make sure you have:

  1. A Supabase account.
  2. A Supabase project with at least one table (if you want to use it as a data source).
  3. The right permissions to connect that project (you’ll be asked to authorize WeWeb).

If you use Supabase Branching, decide which branch you want WeWeb to use (for example main for production).

Connect Supabase in WeWeb

  1. Go to the Settings tab.
  2. Open Integrations.
  3. Select Supabase.
  4. Click Add Integration.
  5. Click Add connection.
  6. Click Connect Supabase, then follow the steps to authorize WeWeb.
  7. Select your Project.
  8. (Optional) Select a Branch (if your Supabase project uses branches).
  9. Select a Secret Key.
    • If you don’t have one yet, choose Create new secret key.
  10. (Optional) If you use a Supabase Custom Domain, paste it in Custom Domain.

WeWeb stores the connection settings per environment (for example Editor, Staging, and Production), so you can connect different Supabase projects or branches for each environment.

Use Supabase as a table data source

You can create a WeWeb table that reads and writes data through Supabase.

  1. Go to Database & APIsTables.
  2. Click + Add table.
  3. In Select a data source, choose Supabase.
  4. Choose the Supabase connection you want to use.
  5. Select the Supabase Table.
  6. Finish setup.

After setup, WeWeb creates an All Rows view so you can start retrieving data right away.

Depending on your setup choices, WeWeb can also create a set of starter API Endpoints for that table (for example “Get row by ID”, “Create row”, “Update row by ID”, and “Delete row by ID”).

Use WeWeb as an API layer on top of Supabase

Supabase has a feature called Row Level Security (RLS). It can be powerful, but it can also be hard to set up correctly for real apps.

If you prefer, you can keep Supabase as your database, and use WeWeb as the “API layer” that controls access.

One pattern some teams use is:

  1. Turn on RLS for your Supabase tables.
  2. Don’t add any RLS policies.
    • With no policies, Supabase will block all user access to that table.
  3. In WeWeb, create the views and API Endpoints you need on top of those Supabase tables.
  4. Secure those views and API Endpoints using WeWeb Security settings (and Middleware workflows if needed).

This works because the Supabase connection in WeWeb includes a Secret Key, so WeWeb can retrieve the data server‑side and then apply your WeWeb security rules before returning anything to the app.

Common pitfalls

The wrong project or environment is connected

If things work in preview but fail in production (or the other way around), check that you connected the right Supabase project and branch for each environment in the connection settings.

“Permission denied” or missing rows

This is usually caused by your Supabase Row Level Security (RLS) setup.

In Supabase, check:

  • Whether RLS is enabled for the table.
  • Whether you have policies that allow the operation you’re trying to do (select, insert, update, delete).
  • Whether the policy conditions match the user you’re testing with.

If RLS feels too complex for your use case, you can keep Supabase as your database and use WeWeb as the layer that secures access instead.

Learn more →

All actions

This integration provides actions you can use in workflows.

ActionDescription
Database | SelectRetrieve rows from a Supabase table, with optional filters, sorting, and pagination.
Database | InsertInsert one or more rows into a Supabase table.
Database | UpdateUpdate one or more rows in a Supabase table (requires filters).
Database | UpsertInsert rows, or update them if they already exist (based on conflict columns).
Database | DeleteDelete one or more rows from a Supabase table (requires filters).
Storage | List FilesList files inside a Supabase Storage bucket.
Storage | Upload FileUpload a file to Supabase Storage.
Storage | Download FileDownload a file from Supabase Storage.
Storage | Update FileReplace an existing file in Supabase Storage.
Storage | Move FileMove/rename a file in Supabase Storage.
Storage | Copy FileCopy a file in Supabase Storage.
Storage | Delete FilesDelete one or more files from Supabase Storage.
Storage | Create Signed URLCreate a time‑limited URL for a private file.
Storage | Get Public URLGet a public URL for a file in a public bucket (optional image transform).
Call Postgres FunctionCall a Postgres function (RPC) in your Supabase project.
Invoke Edge FunctionCall a Supabase Edge Function.
Sign up with emailCreate a user with email and password (Supabase Auth).
Sign in with emailSign in a user with email and password (Supabase Auth).
Sign in with providerSign in using a social provider configured in Supabase Auth.
Fetch userRetrieve the currently signed‑in user from Supabase Auth.
Sign outSign out the currently signed‑in user from Supabase Auth.
Supabase realtimeLearn how realtime channels, broadcast, presence, and database changes work.

Action details

Select

Retrieve rows from a table, with optional filters, sorting, and pagination.

Inputs

FieldDescription
TableThe table to retrieve rows from.
ColumnsWhich columns to return. Leave empty for all columns.
FiltersConditions to limit which rows you retrieve.
Order byColumn to sort by.
DirectionAscending or Descending sorting.
LimitMaximum number of rows to return.
OffsetNumber of rows to skip (useful for pagination).
Single rowReturns one object instead of an array (error if no row found).
Maybe singleReturns one object or null (no error if no row found).
Include countOptionally include a row count in the response.

Insert

Insert one or more rows into a table.

Inputs

FieldDescription
TableThe table to insert into.
DataArray of row objects to insert. Keys are column names.
Return columnsWhich columns to return after insert. Leave empty for all columns.

Update

Update one or more rows in a table.

Inputs

FieldDescription
TableThe table to update.
FiltersAt least one filter is required (safety measure).
DataThe columns to update and their new values.
Return columnsWhich columns to return after update. Leave empty for all columns.

Upsert

Insert rows, or update them if they already exist.

Inputs

FieldDescription
TableThe table to upsert into.
DataArray of row objects to upsert.
On conflict columnsColumns to check for conflicts. Defaults to the primary key if left empty.
Ignore duplicatesIf enabled, duplicate rows are ignored instead of updated.
Return columnsWhich columns to return after upsert. Leave empty for all columns.

Delete

Delete one or more rows from a table.

Inputs

FieldDescription
TableThe table to delete from.
FiltersAt least one filter is required (safety measure).
Return columnsWhich columns to return from deleted rows. Leave empty for all columns.

List Files

List files in a bucket (optionally inside a folder).

Inputs

FieldDescription
BucketThe bucket to list files from.
PathOptional folder path inside the bucket.
LimitMaximum number of files to return.
OffsetNumber of files to skip.
SearchOnly return files that match this search string.
Sort bySort files by name, created date, updated date, or size.

Upload File

Upload a file to a bucket.

Inputs

FieldDescription
BucketThe bucket to upload to.
PathFull path including filename (for example users/123/avatar.png).
FileThe file you want to upload (for example from a file input).
UpsertOverwrite the file if it already exists.
Content typeFile type (MIME type). Usually auto‑detected.
Cache controlCache duration in seconds.

Download File

Download a file from a bucket.

Inputs

FieldDescription
BucketThe bucket to download from.
PathFull path to the file.

Update File

Replace an existing file in a bucket.

Inputs

FieldDescription
BucketThe bucket containing the file.
PathFull path to the existing file to update.
FileThe new file content.
Content typeFile type (MIME type). Usually auto‑detected.
Cache controlCache duration in seconds.

Move File

Move (rename) a file in a bucket.

Inputs

FieldDescription
BucketThe bucket containing the file.
From pathCurrent path of the file.
To pathNew path for the file.

Copy File

Copy a file in a bucket.

Inputs

FieldDescription
BucketThe bucket containing the file.
From pathPath of the file to copy.
To pathDestination path for the copy.

Delete Files

Delete one or more files from a bucket.

Inputs

FieldDescription
BucketThe bucket containing the files.
File pathsAn array of file paths to delete.

Create Signed URL

Create a time‑limited URL for a file (useful for private buckets).

Inputs

FieldDescription
BucketThe bucket that contains the file.
PathFile path inside the bucket.
Expires in (seconds)How long the link should work for.
TransformOptional image resizing/quality options (requires Supabase Pro plan).

Get Public URL

Get a public URL for a file in a public bucket.

Inputs

FieldDescription
BucketThe bucket (must be public).
PathFile path inside the bucket.
DownloadIf enabled, the URL triggers a download.
TransformOptional image resizing/quality options (requires Supabase Pro plan).

Call Postgres Function

Call a Postgres function (RPC) from Supabase.

Inputs

FieldDescription
Function nameThe Postgres function you want to call.
ParametersKey/value parameters for the function.
Single resultReturn a single object instead of an array.

Invoke Edge Function

Call a Supabase Edge Function.

Inputs

FieldDescription
FunctionThe Edge Function to invoke.
MethodHTTP method to use (for example POST).
BodyData you want to send (for POST, PUT, PATCH).
Custom headersOptional headers to send with the request.

Login

Sign in a user with email and password (Supabase Auth).

Inputs

FieldDescription
EmailThe user’s email.
PasswordThe user’s password.

Sign Up

Create a user with email and password (Supabase Auth).

Inputs

FieldDescription
EmailThe user’s email.
PasswordThe user’s password.
User metadataOptional extra profile data to store on the user.
Email redirect URLOptional redirect after the user confirms their email.

Login with Provider

Sign in with a social provider configured in Supabase Auth.

Inputs

FieldDescription
ProviderThe OAuth provider (for example Google or GitHub).
Redirect URLWhere to send the user after sign in.
ScopesOptional extra scopes (space‑separated).
Query parametersOptional extra settings to pass to the provider.

Fetch User

Retrieve the currently signed‑in user.

Inputs

This action has no inputs.

Sign Out

Sign out the currently signed‑in user.

Inputs

This action has no inputs.

Reference

Connection settings

SettingWhat it meansWhere it comes from
ProjectWhich Supabase project WeWeb should use.Selected after you authorize WeWeb.
BranchWhich Supabase branch WeWeb should use.Selected in the connection (only if your project uses branches).
Publishable KeyA key used for safe, public requests.Filled automatically based on the selected project/branch.
Secret KeyA key used for actions that need higher permissions.Selected (or created) in the connection.
Custom DomainA custom API domain for your Supabase project.Optional value from your Supabase dashboard.

FAQs

Do I need different connections for Editor, Staging, and Production?

It depends. Many teams use separate Supabase projects (or branches) for each environment so tests don’t affect real data. WeWeb lets you set this up in the Supabase connection settings.

Can I keep using Supabase as the source of truth?

Yes. When you create a WeWeb table from Supabase, Supabase remains the data source. WeWeb gives you a way to build views, API Endpoints, and access controls on top.

Where do I set redirect URLs for Supabase OAuth sign in?

If you use Login with Provider, set the Redirect URL in the action. This is the page you want the user to land on after they finish signing in.

CONTINUE LEARNING

Browse all available integrations and learn how connections work.

Intro to integrations →