The Supabase MCP Server enables programmatic access to the Supabase Management API, allowing AI models and other clients to manage Supabase projects and organizations through a standardized interface. It serves as a bridge between AI systems and your Supabase resources.
You can set up the Supabase MCP Server by adding configuration to your Claude Config JSON file:
{
"mcpServers": {
"supabase": {
"command": "npx",
"args": [
"y",
"@joshuarileydev/supabase-mcp-server"
],
"env": {
"SUPABASE_API_KEY": "API_KEY_HERE"
}
}
}
}
Make sure to replace API_KEY_HERE
with your actual Supabase API key.
The MCP Server provides functionality for managing both Supabase projects and organizations.
Access a list of all your Supabase projects:
Ask Claude to list all your Supabase projects
Retrieve detailed information about a specific project:
Ask Claude to get details for a specific Supabase project
Set up a new Supabase project:
Ask Claude to create a new Supabase project
Remove a Supabase project:
Ask Claude to delete a specific Supabase project
Get the API keys for a particular project:
Ask Claude to retrieve API keys for a Supabase project
View all your Supabase organizations:
Ask Claude to list all your Supabase organizations
Access detailed information about a specific organization:
Ask Claude to get details for a specific Supabase organization
Set up a new Supabase organization:
Ask Claude to create a new Supabase organization
The server requires the following environment variable:
SUPABASE_API_KEY
: Your Supabase API key for authentication with the Supabase Management APIThere are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json
file so that it is available in all of your projects.
If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json
file.
To add a global MCP server go to Cursor Settings > MCP and click "Add new global MCP server".
When you click that button the ~/.cursor/mcp.json
file will be opened and you can add your server like this:
{
"mcpServers": {
"cursor-rules-mcp": {
"command": "npx",
"args": [
"-y",
"cursor-rules-mcp"
]
}
}
}
To add an MCP server to a project you can create a new .cursor/mcp.json
file or add it to the existing one. This will look exactly the same as the global MCP server example above.
Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.
The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.
You can also explictly ask the agent to use the tool by mentioning the tool name and describing what the function does.