MCPInstall

mcp-supabase

Execute database operations via Supabase MCP (query/write/migration/logs/type generation). Triggers: query/statistics/export/insert/update/delete/fix/backfill/migrate/logs/alerts/type generation. Does not trigger for: pure architecture discussion or code planning. Write operations require confirmation; UPDATE/DELETE without WHERE is refused.

Installs
87
Last 24h
—
Trending rank
—
Security
Not audited

Install

Works with every agent the skills CLI supports.

npx skills add https://github.com/heyvhuang/ship-faster --skill mcp-supabase
  1. 01

    Install

    Run the command in your project. The CLI asks which agents to install for.

  2. 02

    Describe the task

    Ask your agent for something this skill covers. It loads mcp-supabase automatically when relevant.

  3. 03

    Review the result

    The agent follows the SKILL.md steps, scripts and references bundled with the skill.

SKILL.md

The instructions your agent reads when the skill is triggered.

Supabase MCP Skill

Interact with Supabase database via MCP tools, execute queries, writes, migrations, and diagnostics.

Scope

Applies to:

  • Need to perform "database actions" on Supabase: query/statistics/export, write (after confirmation), migration (DDL), type generation, query logs/advisors

Does not apply to:

  • Need to complete "integration implementation" in Next.js project (env/client code/minimal data access layer/project structure)
    → Use workflow-ship-faster (Step 6: Supabase integration) for project-side setup; this skill only handles DB-side actions and gates

Called by:

  • workflow-ship-faster uses this skill as DB operation foundation; workflow-ship-faster handles project-side integration, this skill handles DB-side actions and security gates

Postgres Best Practices (Bundled)

Ship Faster vendors Supabase's Postgres best practices inside the supabase skill (install supabase alongside this skill if you want these references available locally):

  • Full guide: supabase/references/postgres-best-practices/AGENTS.md
  • Individual rules: supabase/references/postgres-best-practices/rules/*.md

Consult it when:

  • Writing/reviewing/optimizing SQL queries
  • Designing indexes, schema changes, or RLS policies
  • Diagnosing performance, locking, or connection issues

When proposing changes, cite the relevant rule file path (for example: supabase/references/postgres-best-practices/rules/query-missing-indexes.md) and keep changes minimal.

File-based Pipeline (Pass Paths Only)

When integrating database operations into multi-step workflows, persist all context and artifacts to disk, passing only paths between agents/sub-agents.

Recommended directory structure (within project): runs/<workflow>/active/<run_id>/

  • Input: 01-input/goal.md (requirements), 01-input/context.json (known tables/fields/IDs)
  • Plan: 03-plans/sql.md (SQL to execute; write operations must be written here before confirmation)
  • Output: 05-final/result.md (conclusion + key numbers + SQL + truncated results)
  • Logs: logs/events.jsonl (summary of each tool call; do not log sensitive field values)

Tool Reference

ToolParametersPurpose
list_tables{"schemas":["public"]}List all tables in specified schema
execute_sql{"query":"SELECT ..."}Execute SQL (query or DML)
apply_migration{"name":"snake_case_name","query":"-- DDL"}Apply database migration
list_migrations{}View existing migrations
generate_typescript_types{}Generate TypeScript type definitions
get_project_url{}Get project URL
get_publishable_keys{}Get public API keys
get_logs{"service":"postgres|api|auth|storage|realtime|edge-function|branch-action"}Query service logs
get_advisors{"type":"security|performance"}Get security/performance recommendations

Optional tools (if enabled):

  • Edge Functions: list_edge_functions, get_edge_function, deploy_edge_function
  • Branching: create_branch, list_branches, merge_branch, reset_branch, rebase_branch, delete_branch

Security Rules (Must Follow)

  1. Read first: Always check schema before any operation
  2. Default LIMIT 50: All SELECT queries default to LIMIT 50, unless user explicitly requests more
  3. Write operation confirmation: INSERT/UPDATE/DELETE must before execution:
    • Display the SQL to be executed
    • State expected number of affected rows
    • Await explicit user confirmation
  4. No bare writes: UPDATE/DELETE without WHERE condition → refuse directly, do not execute
  5. Batch threshold: Affecting > 100 rows → force double confirmation + suggest SELECT count(*) first
  6. DDL via migration: Schema changes must use apply_migration, execute_sql cannot run DDL directly
  7. Production environment: Write disabled by default; only allow when user explicitly says "execute on prod" and double confirms
  8. Sensitive fields: email/phone/token/password are masked or not returned by default, unless user explicitly requests

Operation Flow

1. Parse requirements → restate objective
2. Unsure about tables/fields → first list_tables or execute_sql to query information_schema
3. Plan SQL → present to user
4. Read-only → execute directly
5. Write operation → confirm before execution → verify affected rows → report result

Output Format

  • Language: English
  • Structure: Conclusion → Key numbers → Executed SQL → Result table (max 50 rows)
  • Overflow handling: Truncate + show total count + optional export/pagination

Example output:

✅ Query complete: 142 new users in the last 7 days

Executed SQL:
SELECT DATE(created_at) as date, COUNT(*) as count 
FROM user_profiles 
WHERE created_at > NOW() - INTERVAL '7 days'
GROUP BY DATE(created_at) ORDER BY date DESC;

| date       | count |
|------------|-------|
| 2025-01-09 | 23    |
| 2025-01-08 | 31    |
| ...        | ...   |

Error Handling

SituationAction
SQL syntax errorReturn error summary + fix suggestions
Insufficient permissionsExplain required permissions + alternatives
No data returnedExplain possible reasons (conditions too strict? data doesn't exist?)
RLS blockedSuggest checking RLS policy or using service_role

Example Dialogues

Read: Simple Query

User: Get registered user count for the last 7 days, by day
Execution:
1. Confirm table user_profiles, field created_at
2. Execute aggregation SQL
3. Return: conclusion + numbers + SQL + table

Read: Complex Query

User: Find projects that have runs but all failed
Execution:
1. Confirm projects, runs tables and status field
2. Present JOIN + aggregation SQL
3. Execute and return results (mask email)

Write: Insert

User: Create a new run for project xxx
Execution:
1. First check if project exists
2. Present INSERT SQL + expected impact: 1 row
3. Await confirmation → execute → return new record id

Write: Update

User: Change run abc's status to completed
Execution:
1. First SELECT to verify current state
2. Present UPDATE SQL + WHERE id = 'abc'
3. Confirm → execute → SELECT again to verify

Dangerous: Delete

User: Delete all runs where status = 'failed'
Execution:
1. First SELECT count(*) WHERE status = 'failed'
2. Present count + DELETE SQL
3. If > 100 rows, force double confirmation
4. After confirmation execute → report deleted row count

Dangerous: DELETE without WHERE

User: Clear the runs table
Execution:
❌ Refuse to execute
→ Prompt: DELETE without WHERE condition, this will delete all data
→ Suggest: Use TRUNCATE (requires migration) or add explicit condition

Schema Reference

Get latest schema at runtime:

-- List all tables
SELECT table_name FROM information_schema.tables 
WHERE table_schema = 'public';

-- View table structure
SELECT column_name, data_type, is_nullable 
FROM information_schema.columns 
WHERE table_name = '<table_name>';

For project-specific schema (may be outdated), see schema.md. Default to information_schema / generate_typescript_types as source of truth.

FAQ

What does the mcp-supabase skill do?

Execute database operations via Supabase MCP (query/write/migration/logs/type generation). Triggers: query/statistics/export/insert/update/delete/fix/backfill/migrate/logs/alerts/type generation. Does not trigger for: pure architecture discussion or code planning. Write operations require confirmation; UPDATE/DELETE without WHERE is refused.

How do I install mcp-supabase?

Run npx skills add https://github.com/heyvhuang/ship-faster --skill mcp-supabase in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/mcp-supabase/ (personal) or .claude/skills/mcp-supabase/ (project).

Which AI agents can use mcp-supabase?

Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.

Is mcp-supabase safe to install?

No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.

Who maintains mcp-supabase?

It is published by heyvhuang in heyvhuang/ship-faster. It has 87 recorded installs.

More from heyvhuang/ship-faster

View all →

mcp-stripe

heyvhuang/ship-faster

Stripe MCP transaction operations skill. Execute transaction operations via Stripe MCP server (https://mcp.stripe.com): customer management, products/prices, invoices, payment links, subscriptions, refunds, dispute handling, balance queries. Triggers: user requests Stripe operations including create customer, create product, create invoice, generate payment link, query transactions, process refunds, manage subscriptions, view disputes, check balance, etc.

Backend & APIs747 installs

review-doc-consistency

heyvhuang/ship-faster

Open the skill to read its SKILL.md instructions.

tool-ast-grep-rules

heyvhuang/ship-faster

Write AST-based code search and rewrite rules using ast-grep YAML. Create linting rules, code modernizations, and API migrations with auto-fix. Use when the user mentions ast-grep, tree-sitter patterns, code search rules, lint rules with YAML, AST matching, or code refactoring patterns.

tool-openclaw

heyvhuang/ship-faster

Help users install, configure, operate, and migrate OpenClaw (gateway, channels, nodes, plugins, model/auth setup). Use when answering OpenClaw setup/debug questions or model migration questions; use the local docs snapshot bundled with this skill as the source of truth. Triggers: openclaw, clawdbot, clawd, clawdhub, gateway, onboard, channels login, whatsapp, telegram, discord, mattermost, pairing, nodes, sandboxing, tailscale, provider migration, Claude to GPT, model swap.

tool-ui-ux-pro-max

heyvhuang/ship-faster

Open the skill to read its SKILL.md instructions.

deep-research

heyvhuang/ship-faster

Research a topic thoroughly in this repo and return a structured summary with file references. Use when you need to understand how something works, find patterns across modules, or audit implementations.

Popular data & databases skills

View category →

Postgres best practices maintained by Supabase, for Postgres running anywhere. Load this skill BEFORE writing or changing anything that lives in a Postgres database: creating or altering tables and columns (including choosing column types), schema design, migrations and declarative schema files, RLS policies and the tests that verify them, indexes, triggers, database functions, queues and scheduled jobs (pgcron, pgmq), vector/semantic search (pgvector), and restoring dumps (pgrestore) or importing data. Also load it when diagnosing slow queries, high CPU, timeouts, EXPLAIN plans, connection exhaustion, locking, bloat, or rows visible to the wrong user or tenant. This is not just a performance guide — schema, migration, security, and SQL authoring tasks need these rules too, even for a one-column change or a single query.

OfficialData & Databases462.2K installs

prisma-client-api

prisma/skills

Prisma Client API reference covering model queries, filters, operators, and client methods. Use when writing database queries, using CRUD operations, filtering data, or configuring Prisma Client. Triggers on "prisma query", "findMany", "create", "update", "delete", "$transaction".

OfficialData & Databases393.5K installs

Deprecated compatibility name for prisma-orm-setup. Use only when a user or existing integration explicitly invokes prisma-database-setup; otherwise select prisma-orm-setup.

OfficialData & Databases392.3K installs

prisma-cli

prisma/skills

Prisma ORM 7 CLI reference for existing Prisma 7 applications or explicitly selected Prisma 7 workflows. Covers prisma init, generate, migrate, db, dev, studio, and mcp. For setup, connection repair, or Prisma 8, use prisma-orm-setup; not the Prisma Platform CLI.

OfficialData & Databases390.8K installs

prisma-postgres

prisma/skills

Deprecated compatibility name for prisma-postgres-setup. Use only when a user or existing integration explicitly invokes prisma-postgres; otherwise select prisma-postgres-setup.

OfficialData & Databases384.4K installs

Required reference for Prisma ORM 7 SQL driver adapter work. Use when implementing or modifying adapters, adding database drivers, or touching SqlDriverAdapter, Transaction, savepoint, result mapping, or DriverAdapterError behavior. Covers current transaction lifecycle, optional savepoint hooks, original database-error preservation, and verification.

OfficialData & Databases378.9K installs