Supabase (Experimental)
Use Supabase for auth, database and server functions.
What is Supabase
Supabase is an open-source backend platform that offers auth, a PostgreSQL database, edge functions, and more—all with a generous free tier. It's a great choice for quickly launching and scaling new projects.
Setup
Connecting to Supabase only takes a couple of minutes—and even faster if you're already familiar with it.
Enabling Supabase
Support for Supabase is currently experimental, which means some things might not work as expected. To enable it, go to Settings and toggle on Enable Supabase integration.
If you run into any issues, please report a bug!
Connecting to Supabase
When you chat in Dyad and request a backend-related feature, Dyad will ask if you’d like to connect to Supabase. Click the button, and you’ll be taken to your app’s details page where you’ll see a Connect Supabase button that looks like this:
Clicking Connect Supabase opens your browser and prompts you to review the permissions you want to grant Dyad. Choose the Supabase organization you’d like to connect.
Only you can access your Supabase resources through Dyad. Your access token is securely stored locally on your computer.
After submitting your selection on Supabase’s site, you’ll be redirected back to Dyad. The Dyad app should automatically reopen. If it doesn’t, click the button on the site to reopen it manually. Once that’s done, your Supabase connection is complete.
Selecting a Supabase Project
For each Dyad app you want to use with Supabase, you’ll need to choose a Supabase project. While you can reuse the same project across multiple apps, it’s usually simpler and safer to create a separate project for each one.
Using Supabase
Once setup is complete, you’re ready to use Supabase in your Dyad app! Just start chatting—Dyad will handle Auth, Database, and Server Functions using Supabase.
Auth
Supabase Auth is straightforward, especially with the default email/password method. You can ask Dyad to add authentication like this:
Add auth and make users login
By default, Supabase requires email confirmation when users sign up. You can disable this in your Supabase dashboard settings.
Database
Supabase Database lets you store and manage data. It also supports Row-Level Security (RLS), which allows secure, fine-grained access directly from the browser (e.g., your Dyad app) based on customizable policies.
Dyad usually generates reasonable default RLS policies, but you should review and adjust them to fit your specific needs.
Server Functions
Supabase Edge Functions—also referred to as Server Functions—run on Supabase's servers rather than in the browser. Think of them as remote functions you can easily call from your app.
They’re especially useful for tasks requiring private API keys (like calling the OpenAI API) because they keep sensitive keys out of the browser, avoiding common security issues.
Other Features
Supabase offers many features beyond those listed here. While Dyad’s integration hasn’t been tested with all of them, some may still work. If you encounter any issues, please let us know.