MCP cover image
Alexander-zuev_supabase-mcp-server logo
Public

Alexander-zuev_supabase-mcp-server

See in Github
2025-02-16

Espejo dehttps: //github.com/alexander-zuev/supabase-mcp-server

0

Github Watches

1

Github Forks

0

Github Stars

Supabase MCP Server

Supabase    MCP

Let Cursor & Windsurf interact with Supabase

Implementaton of Supabase MCP server that enables Cursor and Windsurf to interact directly with Supabase PostgreSQL database. It provides a set of database management tools that work seamlessly with these IDEs through the MCP protocol.

Key features

  • 💻 Works with both Windsurf and Cursor IDEs
  • ✅ Supports local Supabase projects and production Supabase projects
  • 🔨 Built-in database exploration tools with schema insights
  • 🔐 Secure read-only database access
  • 🔍 SQL query validation

Prerequisites

  • Python 3.12+
  • PostgreSQL 16+
  • uv package manager

Mac-specific Setup

  1. PostgreSQL Installation (Required for psycopg2)

    brew install postgresql@16
    

    ⚠️ Important: PostgreSQL must be installed BEFORE installing project dependencies. The psycopg2 package requires PostgreSQL development libraries during compilation.

  2. uv Package Manager

    pip install uv
    

Windows Setup

  1. PostgreSQL Installation

  2. uv Package Manager

    pip install uv
    

Installation

  1. Clone and setup environment
git clone https://github.com/alexander-zuev/supabase-mcp-server.git
cd supabase-mcp-server

# Create and activate virtual environment
uv venv

# Mac/Linux
source .venv/bin/activate
# Windows
.venv\Scripts\activate
  1. Install dependencies
uv sync

📝 If you get psycopg2 compilation errors, make sure you've installed PostgreSQL first!

Usage

Local Development

MCP server connects to your local Supabase project by default:

  • Host: 127.0.0.1:54322
  • Password: postgres

Production Setup

For staging or production Supabase projects, set these environment variables (setup differs for Cursor and Windsurf):

SUPABASE_PROJECT_REF="your-project-ref"  # e.g., "abcdefghijklm"
SUPABASE_DB_PASSWORD="your-db-password"

Cursor Setup

Add an MCP server with this configuration:

name: supabase
protocol: stdio
command: uv --directory /path/to/cloned/supabase-mcp-server run main.py

Example with actual path:

command: uv --directory /Users/az/cursor/supabase-mcp-server run main.py

After adding this configuration, Agent mode will have access to all database tools.

Windsurf

Windsurf relies on a 'Claude Desktop' like configuration to connect to MCP server. This means you need to edit mcp_config.json file to connect to MCP server:

{
  "mcpServers": {
    "supabase": {
      "command": "/Users/az/.local/bin/uv",
      "args": [
        "--directory",
        "/Users/username/cursor/supabase-mcp-server",  // Your repository path
        "run",
        "main.py"
      ],
      "env": {
        "SUPABASE_PROJECT_REF": "127.0.0.1:54322",  // Local development default
        "SUPABASE_DB_PASSWORD": "postgres"  // Local development default
      }
    }
  }
}

After saving and refreshing, Cascade will have access to all database tools.

Development

  1. Start the development server
mcp dev main.py
  1. Start your local Supabase instance
supabase start

Future improvements

  • 🐍 Support methods and objects available in native Python SDK
  • 🔍 Improve SQL syntax validation

相关推荐

  • NiKole Maxwell
  • I craft unique cereal names, stories, and ridiculously cute Cereal Baby images.

  • https://jgadvisorycpa.com
  • This GPT assists in finding a top-rated business CPA - local or virtual. We account for their qualifications, experience, testimonials and reviews. Business operators provide a short description of your business, services wanted, and city or state.

  • https://suefel.com
  • Latest advice and best practices for custom GPT development.

  • Yusuf Emre Yeşilyurt
  • I find academic articles and books for research and literature reviews.

  • https://maiplestudio.com
  • Find Exhibitors, Speakers and more

  • Carlos Ferrin
  • Encuentra películas y series en plataformas de streaming.

  • Joshua Armstrong
  • Confidential guide on numerology and astrology, based of GG33 Public information

  • Emmet Halm
  • Converts Figma frames into front-end code for various mobile frameworks.

  • Elijah Ng Shi Yi
  • Advanced software engineer GPT that excels through nailing the basics.

  • lumpenspace
  • Take an adjectivised noun, and create images making it progressively more adjective!

  • apappascs
  • Descubra la colección más completa y actualizada de servidores MCP en el mercado. Este repositorio sirve como un centro centralizado, que ofrece un extenso catálogo de servidores MCP de código abierto y propietarios, completos con características, enlaces de documentación y colaboradores.

  • ShrimpingIt
  • Manipulación basada en Micrypthon I2C del expansor GPIO de la serie MCP, derivada de AdaFruit_MCP230xx

  • OffchainLabs
  • Implementación de la prueba de estaca Ethereum

  • modelcontextprotocol
  • Servidores de protocolo de contexto modelo

  • huahuayu
  • Una puerta de enlace de API unificada para integrar múltiples API de explorador de blockchain similar a Esterscan con soporte de protocolo de contexto modelo (MCP) para asistentes de IA.

  • Mintplex-Labs
  • La aplicación AI de escritorio todo en uno y Docker con trapo incorporado, agentes de IA, creador de agentes sin código, compatibilidad de MCP y más.

    Reviews

    2 (1)
    Avatar
    user_vFjxP76t
    2025-04-15

    I have been using Aiyogg_tinypng Mcp Server by MCP-Mirror for several months now, and it has significantly optimized my PNG files with impressive efficiency. The user interface is straightforward, making it a breeze to navigate. Highly recommend it for anyone looking to reduce file sizes without sacrificing quality. Check it out here: https://mcp.so/server/aiyogg_tinypng-mcp-server/MCP-Mirror