Netlify MCP server

Integrates with Netlify's API to enable automated web deployment, serverless function management, and continuous deployment workflows for AI applications.
Back to servers
Setup instructions
Provider
Dynamic Endpoints
Release date
Feb 22, 2025
Language
TypeScript
Stats
6 stars

The Netlify MCP Server is a comprehensive Model Context Protocol server that provides access to all Netlify CLI features through the latest MCP SDK and Netlify CLI. It offers 43 tools covering functionalities like deployments, blobs storage, dev server, recipes, analytics, forms, and advanced API operations.

Installation

Installing via Smithery

To install Netlify MCP Server for Claude Desktop automatically:

npx -y @smithery/cli install @DynamicEndpoints/Netlify-MCP-Server --client claude

Manual Installation

  1. Clone the repository:
git clone <repository-url>
cd Netlify-MCP-Server
  1. Install dependencies:
npm install
  1. Build the project:
npm run build
  1. Ensure Netlify CLI is installed:
npm install -g netlify-cli@latest

Authentication

Since the server runs non-interactively, you must use a Personal Access Token (PAT):

  1. Generate a PAT:

    • Go to Netlify User Settings > Applications > Personal access tokens
    • Select New access token
    • Give it a description (e.g., "MCP Server Token")
    • Set an expiration date
    • Generate and copy the token immediately
  2. Configure the Token: Make this token available as the NETLIFY_AUTH_TOKEN environment variable in your MCP settings.

Configuration

Add this configuration to your MCP settings file:

{
  "mcpServers": {
    "netlify": {
      "command": "node",
      "args": ["C:\\path\\to\\Netlify-MCP-Server\\build\\index.js"],
      "env": {
        "NETLIFY_AUTH_TOKEN": "YOUR_NETLIFY_PAT_HERE"
      },
      "disabled": false,
      "autoApprove": []
    }
  }
}

Settings file locations:

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

Core Tools

Site Deployment

deploy-site

Deploy a site directory to Netlify.

{
  "path": "./dist",
  "prod": true,
  "message": "Deploying latest changes"
}

list-sites

List all Netlify sites linked to your account.

{}

trigger-build

Trigger a new build/deploy for a site.

{
  "siteId": "your-site-id-here",
  "message": "Triggering rebuild"
}

Site Management

create-site

Create a new site on Netlify.

{
  "name": "my-awesome-new-site"
}

delete-site

Delete a site from Netlify.

{
  "siteId": "site-id-to-delete",
  "force": true
}

link-site

Link the current project directory to a Netlify site.

{
  "siteId": "your-site-id-here"
}

unlink-site

Unlink the current project directory from the associated Netlify site.

{}

Environment Variables

set-env-vars

Set environment variables for a site.

{
  "siteId": "your-site-id-here",
  "envVars": {
    "API_KEY": "secret123",
    "NODE_ENV": "production"
  }
}

get-env-var

Get the value of a specific environment variable.

{
  "siteId": "your-site-id-here",
  "key": "API_KEY"
}

unset-env-var

Delete an environment variable.

{
  "siteId": "your-site-id-here",
  "key": "OLD_VAR"
}

import-env

Import environment variables from a .env file.

{
  "siteId": "your-site-id-here",
  "filePath": ".env.production",
  "replace": true
}

Netlify Blobs Storage

get-blob

Get a blob from storage.

{
  "storeName": "my-store",
  "key": "data.json"
}

set-blob

Set/store a blob.

{
  "storeName": "my-store",
  "key": "data.json",
  "data": "{ \"hello\": \"world\" }"
}

delete-blob

Delete a blob from storage.

{
  "storeName": "my-store",
  "key": "old-data.json"
}

list-blobs

List all blobs in a store.

{
  "storeName": "my-store",
  "prefix": "users/"
}

Development Tools

start-dev-server

Start Netlify dev server locally.

{
  "dir": "./",
  "port": 8888
}

serve-built-site

Serve a built site locally.

{
  "dir": "./dist",
  "port": 8000
}

Recipes & API

list-recipes

List available Netlify recipes.

{}

run-recipe

Run a specific Netlify recipe.

{
  "recipeName": "create-react-app"
}

call-netlify-api

Make direct Netlify API calls.

{
  "path": "/api/v1/sites",
  "method": "GET"
}

Forms & Analytics

get-form-submissions

Get form submissions for a site.

{
  "siteId": "your-site-id-here",
  "formId": "form-123"
}

get-analytics

Get site analytics data.

{
  "siteId": "your-site-id-here",
  "period": "30d"
}

Available Resources

Access Netlify data directly using these resource URIs:

  • netlify://sites - List all sites
  • netlify://sites/{siteId}/overview - Complete site overview
  • netlify://sites/{siteId}/functions - List site functions
  • netlify://sites/{siteId}/env - List environment variables
  • netlify://sites/{siteId}/deploys - List site deployments
  • netlify://sites/{siteId}/forms - Form submissions and configuration
  • netlify://sites/{siteId}/analytics - Site usage analytics
  • netlify://blobs/{storeName} - Netlify Blobs storage management
  • netlify://recipes - Netlify automation recipes
  • netlify://api/methods - Available Netlify API endpoints

Limitations

  • Commands requiring interactive prompts (like netlify login) are not supported
  • Many commands require site context via the NETLIFY_SITE_ID environment variable
  • Commands that operate on the current working directory may not function as expected
  • Browser-dependent features have limited functionality in the MCP server environment

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 "netlify" '{"command":"node","args":["C:\\path\\to\\Netlify-MCP-Server\\build\\index.js"],"env":{"NETLIFY_AUTH_TOKEN":"YOUR_NETLIFY_PAT_HERE"},"disabled":false,"autoApprove":[]}'

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": {
        "netlify": {
            "command": "node",
            "args": [
                "C:\\path\\to\\Netlify-MCP-Server\\build\\index.js"
            ],
            "env": {
                "NETLIFY_AUTH_TOKEN": "YOUR_NETLIFY_PAT_HERE"
            },
            "disabled": false,
            "autoApprove": []
        }
    }
}

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": {
        "netlify": {
            "command": "node",
            "args": [
                "C:\\path\\to\\Netlify-MCP-Server\\build\\index.js"
            ],
            "env": {
                "NETLIFY_AUTH_TOKEN": "YOUR_NETLIFY_PAT_HERE"
            },
            "disabled": false,
            "autoApprove": []
        }
    }
}

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