Vercel MCP server

Integrates with Vercel's serverless infrastructure to provide a lightweight endpoint for AI model interactions and tasks like chatbots, content generation, and data analysis.
Back to servers
Setup instructions
Provider
nganiet
Release date
Dec 28, 2024
Language
TypeScript
Stats
54 stars

The Vercel MCP Integration provides programmatic access to Vercel deployment management through AI Assistants like Claude and Cursor. It implements Vercel's core API endpoints as tools, enabling you to monitor deployments, manage environment variables, track project status, and handle team operations through a Model Context Protocol server.

Prerequisites

  • Node.js 18+
  • Vercel API Token
  • MCP Client (Claude, Cursor, or other AI Assistants that support MCP)

Installation

git clone [your-repo-url]
cd vercel-mcp
npm install

Configuration

  1. Create .env file:
VERCEL_API_TOKEN=your_api_token_here
  1. Start MCP server:
npm start

Integrating with AI Assistants

Integrating with Claude

  1. Start the MCP server locally with npm start
  2. In Claude Code, use the /connect command:
    /connect mcp --path [path-to-server]
    
  3. Claude will automatically discover the available Vercel tools
  4. Ask Claude to perform Vercel operations:
    Please list my recent Vercel deployments using the vercel-list-all-deployments tool
    
  5. Alternatively, expose the MCP server as an HTTP server:
    npm install -g @modelcontextprotocol/proxy
    mcp-proxy --stdio --cmd "npm start" --port 3399
    
    Then connect in Claude: /connect mcp --url http://localhost:3399

Integrating with Cursor

  1. Start the MCP server with npm start
  2. In Cursor, access Settings → Tools
  3. Under "Model Context Protocol (MCP)", click "+ Add MCP tool"
  4. Configure a new connection:
    • For stdio transport: Point to the executable path
    • For HTTP transport: Specify the URL (e.g., http://localhost:3399)
  5. Cursor will automatically discover the available Vercel tools
  6. Use Cursor's AI features to interact with your Vercel deployments

Programmatic Integration

Use the Model Context Protocol SDK in your own applications:

import { Client } from "@modelcontextprotocol/sdk/client";

// Create an MCP client connected to a stdio transport
const client = new Client({
  transport: "stdio",
  cmd: "npm --prefix /path/to/vercel-mcp start",
});

// Or connect to an HTTP transport
const httpClient = new Client({
  transport: "http",
  url: "http://localhost:3399",
});

// Connect to the server
await client.connect();

// List available tools
const { tools } = await client.listTools();
console.log(
  "Available tools:",
  tools.map((t) => t.name)
);

// Call a tool
const result = await client.callTool({
  name: "vercel-list-all-deployments",
  args: { limit: 5 },
});

console.log("Deployments:", result);

Tool Usage Examples

List Recent Deployments

const response = await mcpClient.callTool({
  name: "vercel-list-all-deployments",
  args: {
    limit: 5,
    target: "production",
  },
});

Create a New Project

const project = await mcpClient.callTool({
  name: "vercel-create-project",
  args: {
    name: "my-awesome-project",
    framework: "nextjs",
    teamId: "team_1a2b3c4d5e6f7g8h9i0j1k2l",
  },
});

Deploy from Git

const deployment = await mcpClient.callTool({
  name: "vercel-create-deployment",
  args: {
    project: "my-project-id",
    gitSource: {
      type: "github",
      ref: "main",
    },
  },
});

Docker Deployment

Build the Image

docker build -t vercel-mcp .

Run Container

docker run -it --rm \
  -e VERCEL_API_TOKEN=your_token_here \
  -p 3399:3399 \
  vercel-mcp

Production Deployment

docker run -d \
  --name vercel-mcp \
  --restart unless-stopped \
  -e VERCEL_API_TOKEN=your_token_here \
  -p 3399:3399 \
  vercel-mcp

Environment Variables

Variable Description Required
VERCEL_API_TOKEN Vercel access token Yes

How to install this MCP server

For Claude Code

To add this MCP server to Claude Code, run this command in your terminal:

claude mcp add-json "vercel" '{"command":"npx","args":["-y","vercel-mcp"]}'

See the official Claude Code MCP documentation for more details.

For Cursor

There 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.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "vercel": {
            "command": "npx",
            "args": [
                "-y",
                "vercel-mcp"
            ]
        }
    }
}

Adding an MCP server to a project

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.

How to use the MCP server

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 explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.

For Claude Desktop

To add this MCP server to Claude Desktop:

1. Find your configuration file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json

2. Add this to your configuration file:

{
    "mcpServers": {
        "vercel": {
            "command": "npx",
            "args": [
                "-y",
                "vercel-mcp"
            ]
        }
    }
}

3. Restart Claude Desktop for the changes to take effect

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later