Skip to content

Supabase connector

Connect your own Supabase project to a Genesis project. Your site reads and writes your database, signs people in with Supabase Auth, uploads files and receives live updates. Give the AI access as well, and it works on the Supabase project itself: it creates tables and security policies, reads your data, sets up file uploads and deploys Edge Functions.

This is different from Dedicated Cloud, where ESTAGE runs the backend for you. A project uses one or the other, not both.

  • A Supabase project you own. Its plan doesn’t matter.
  • A Genesis project without a Dedicated Cloud. If the project already has one, Genesis doesn’t save the Supabase connector — use the Dedicated Cloud there, or connect Supabase to another project.
  • To give the AI access: permission to manage the Supabase organization that holds the project.
  1. In your Supabase dashboard, open Project Settings and copy the Project URL (https://<ref>.supabase.co) and the Publishable key (sb_publishable_…; on older projects, the anon key).
  2. In Genesis, open Settings → Connectors and choose Supabase.
  3. Paste them into Project URL and Publishable (anon) key.
  4. Select Connect.

The publishable key is public by design: it ships with your site, and what visitors may do is decided by the Row Level Security (RLS) policies on your tables.

With only these two fields, the AI writes the code your site needs, but it can’t see or change your database. You create the tables and policies in Supabase yourself — or give the AI access.

The Admin setup box in the Supabase connector holds a credential that stays on ESTAGE’s servers and never ships with your site. Use one of these two ways.

  1. In Admin setup, select Connect Supabase.
  2. Supabase opens. Sign in, choose the organization that holds your project, and approve access.
  3. Back in Genesis, choose your project in Supabase project. With only one project, it’s chosen for you.
  4. Select Save.
  1. In Supabase, open your account’s Access Tokens page and generate a token. It starts with sbp_.
  2. In Admin setup, paste it into Management access token.
  3. Fill in Project ref — the <ref> part of your Project URL.
  4. Select Save.

Either way, the access reaches every project the Supabase account or organization can open, not only this one. The AI works in the project you chose. To keep your other projects out of reach, keep this one in its own Supabase organization.

Saving the connector — and every publish after it — also points your project’s Supabase Auth Site URL and redirect list at your site, so confirmation and password-reset emails link to your site instead of localhost:3000. Genesis adds your addresses to the list and replaces the Site URL only while it’s still the Supabase default.

Ask in the chat in plain words. The AI picks the steps.

You askWhat the AI does
“Add a contact form that saves messages to a messages table”Creates the table and the policies visitors need, then builds the form
“Show my latest posts on the home page”Reads the table’s structure, adds a read policy if one is missing, builds the section
“How many people signed up this week?”Reads your data and answers — reading never changes anything
“Let members upload a profile photo”Creates a public storage bucket and an upload function, then wires the upload
“Calculate order totals on the server so visitors can’t change prices”Deploys a Supabase Edge Function and calls it from the site
“Confirmation emails open localhost”Points your Supabase Auth addresses at your site

Your live site changes on the next publish.

  • Reading is read-only. When the AI looks at your tables or rows, the database itself refuses any change.
  • Nothing that deletes data runs without you. Before the AI drops a table or a column, empties a table, or deletes or overwrites every row, it stops, tells you exactly what would be lost and waits for your answer. It prefers a change that keeps your data, such as adding a column.
  • Policies decide what visitors can do. When a form or a page on your site gets an error, the table usually lacks a policy for that action. Ask the AI to fix it.
  • Taking the AI’s access away: revoke the token on Supabase’s Access Tokens page, or remove ESTAGE from the apps authorized in your Supabase organization’s settings. Your site keeps working with the publishable key.
  • Disconnecting the project: in Settings → Connectors → Supabase, select Disconnect. The code the AI wrote stays in the project — ask the AI to remove it if you no longer need it.
  • One Supabase backend per project. While the connector is on, a Dedicated Cloud can’t be activated in the project. To move to a Dedicated Cloud, disconnect Supabase first. Your data stays in your Supabase project.
  • Without access, the AI can’t create tables for you. It still writes the site’s code; create the tables and policies in Supabase’s SQL editor, or add access later.
  • See Connectors for the other services you can connect.