How to Configure Windsurf Supabase Credentials

Published
Length
3 min read

Luis Felipe Dias

All posts

To set up windsurf supabase credentials, create a dedicated Postgres role and pass its login string to the agent. Do not use the default admin password that you set when you created the project. Teams often put their main database login into local shell files for quick testing. When an AI coding agent reads those files, it gains full admin rights over every table. How windsurf supabase credentials work in practice On June 2, 2026, Cognition renamed Windsurf to Devin Desktop, while keeping the

Your coding agents run with your access.

Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.

To set up windsurf supabase credentials, create a dedicated Postgres role and pass its login string to the agent. Do not use the default admin password that you set when you created the project. Teams often put their main database login into local shell files for quick testing. When an AI coding agent reads those files, it gains full admin rights over every table.

How windsurf supabase credentials work in practice

On June 2, 2026, Cognition renamed Windsurf to Devin Desktop, while keeping the same IDE features. Its agent, Cascade, can run terminal commands on its own after the user gives permission. Cascade runs inside a dedicated terminal that loads your local shell setup on macOS or Linux. Any database variables or aliases stored in your shell profile are open to the agent.

The agent can also talk to external tools through Model Context Protocol servers. Whether the agent uses a server or a terminal command, it needs a database login. Every Supabase project starts with a default postgres role that holds admin rights. Supabase does not grant true superuser access because that allows destructive database actions.

Even so, the default postgres role has extra rights for high-level admin tasks. The password you set at project creation belongs to this default admin role. Supabase warns teams never to share this password with an external service unless they trust it completely. Instead, the vendor recommends making a brand new database user for each tool or service.

Every new project also comes with built-in roles like anon, authenticated, service_role, and authenticator. These built-in roles fit web apps, while a custom role fits an AI coding assistant best. You can run SQL in the Supabase Dashboard to create a read-only role for your agent. Queries run in the Dashboard run as the postgres admin and carry a dashboard source comment.

What native roles solve and what stays exposed

Creating a separate Postgres role for your IDE limits what the agent can touch at rest. You can grant select rights on specific tables and block drop or truncate actions. If the agent makes a mistake in a terminal session, the database blocks destructive schema changes. This native setup handles basic login checks and table-level permissions well.

Still, static database roles only check who logs in at the start of a session. They do not inspect what individual SQL statements or commands do while in flight. Once the agent logs in with a valid password, it can read every row in allowed tables. If those tables hold customer emails, phone numbers, or card numbers, the agent pulls them into context.

Ephemeral Credentials + End-to-End Encryption: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Storing plain passwords in shell profiles or local files also creates a sharing problem. Every developer on the team has to manage, rotate, and guard their own local database keys. If a developer gives the agent write rights for a quick fix, those broad rights often stay active. Native roles alone cannot mask sensitive fields in query results or pause risky statements for human approval.

Steps to tighten local agent database sessions

Start by removing the default postgres admin password from all local project files and shell profiles. Next, log into the Supabase Dashboard and create a dedicated role just for your coding agent. Grant that role access only to the schemas and tables needed for daily development work. Never give this role permission to alter users or copy data from external programs.

Keep local development data separate from live customer records whenever your team builds new features. Even with a scoped role, review every terminal command before you allow the agent to run it. When the agent needs to touch live systems, pair native roles with statement-level checks and field masking.

Add query and result controls beside Postgres

Grants and pools govern who logs into PostgreSQL. Yet every query in an open session still runs with that role's full scope. In practice, hoop.dev sits inline in the wire protocol beside your database as a sidecar for your Postgres. For every plain or prepared query an agent or human runs against production, hoop.dev decides to pass, mask, block, or escalate it for review.

When a tool or agent sends SQL, hoop.dev Postgres controls block banned statements before execution or hold risky ones for human approval via an AI Analyzer you configure. Matched sensitive columns in result rows are masked in memory before they reach the caller. Each query and decision is logged per listener, which generates evidence for SOC 2, HIPAA, and GDPR audits. View the binary on GitHub.

Frequently asked questions

Is Windsurf now called Devin Desktop?

Yes, Cognition announced on June 2, 2026, that Windsurf is now called Devin Desktop. It keeps the same IDE features, and the old docs links now point to the Devin Desktop docs.

Should I give my AI agent the default Supabase postgres password?

No, the password set at project creation belongs to the default postgres role, which has admin rights. Supabase recommends creating a separate database user for each external tool or service you use.

How does the Windsurf agent read my local database variables?

The agent runs commands in a dedicated bash or zsh terminal that loads your user shell profile. Any database variables or aliases saved in your shell setup are available to the agent during its session.

The query runs. The emails stay hidden.