• AI MVP Weekly
  • Posts
  • How I set up Supabase MCP inside Cursor (step-by-step)

How I set up Supabase MCP inside Cursor (step-by-step)

Full setup guide: Supabase + MCP + Cursor explained in simple steps

Hey,

Building MVPs the traditional way is slow and painful.

You waste time setting up databases, writing boilerplate, managing API integrations, and debugging endless migrations before you even test with real users.

That’s why I started building client projects with a different stack: Cursor + Supabase + MCP.

It has completely changed the way I build. Here’s the full breakdown of how it works and how you can set it up yourself.

Why this stack works

  • Cursor → AI co-developer that generates UI, connects APIs, and optimizes your code

  • Supabase → scalable backend with PostgreSQL, auth, RLS, and realtime syncing

  • MCP → the bridge that lets Cursor query and update your Supabase schema in real time

Together they automate 80% of the backend work so you can focus on shipping faster.

Step 1: Build the frontend with Cursor

Cursor isn’t just autocomplete. It can:

  • Generate React/Next.js components instantly

  • Automate TypeScript setup

  • Optimize and refactor your code

  • Connect APIs and databases seamlessly

Think of it as an AI pair programmer that knows your entire project.

Step 2: Use Supabase as the backend

Supabase gives you:

  • PostgreSQL database with full flexibility

  • Built-in auth (OAuth, email, magic links)

  • Row-Level Security (RLS) for protecting user data

  • Realtime sync between frontend and backend

It’s backend-as-a-service that scales with you.

Step 3: Automate migrations

Normally, migrations = manual SQL scripts + schema headaches.

With Cursor + Supabase, you just describe what you want and it generates the migration files instantly.

No more writing SQL by hand.

Step 4: Connect MCP to Cursor

MCP lets Cursor talk directly to your Supabase database. Setup is simple:

  1. Create a personal access token inside Supabase

  2. Create .cursor/mcp.json in your project

  3. Add this config:

{
  "mcpServers": {
    "supabase": {
      "command": "npx",
      "args": [
        "-y",
        "@supabase/mcp-server-supabase@latest",
        "--access-token",
        "<personal-access-token>"
      ]
    }
  }
}
  1. Replace <personal-access-token> with yours

  2. Save and check Cursor → Settings → MCP. It should show active in green

Now Cursor can fetch and update your schema automatically.

👉 Official docs: Supabase MCP setup

Step 5: Secure your app

Supabase supports RLS (Row-Level Security), and Cursor can generate policies automatically.

This means AI helps enforce access control and prevents unauthorized data leaks — a step most MVPs skip.

Step 6: Sync databases

Cursor can also keep your local and production databases in sync without conflicts. No more mismatches or broken migrations.

Step 7: Deploy

Once your app is tested:

  • Run supabase db push to sync

  • Deploy frontend on Vercel or Netlify

  • Update environment variables

That’s it. Your MVP is live.

Video walkthrough

I thought about recording my own, but there’s already a great one available.

Watch this step-by-step tutorial from MakerThrive on how to set up Supabase MCP inside Cursor (or any AI IDE):

Why this matters

With this workflow I can:

  • Ship MVPs 5x faster

  • Automate 80% of repetitive backend work

  • Deliver secure, production-ready apps for clients in weeks, not months

This has transformed my agency workflow, and I think it’s the future of AI-powered building.

If you found this valuable, I go much deeper inside AI MVP Builders with video walkthroughs, prompts, and step-by-step systems.

👉 Join here: AI MVP Builders

Keep building,

Prajwal