Recraft AI MCP server

Integrates with Recraft's image generation API to create and edit raster and vector images, apply custom styles, manipulate backgrounds, upscale images, and perform vectorization with fine-grained control over artistic properties.
Back to servers
Setup instructions
Provider
Recraft AI
Release date
May 28, 2025
Stats
16 stars

The Recraft MCP Server integrates MCP clients with Recraft's powerful image operations, allowing you to generate and manipulate both raster and vector images. By connecting this server to your MCP client, you can access features like image generation, editing, custom styles, vectorization, background removal, and upscaling.

Installation Options

Prerequisites

Before installing the Recraft MCP Server, you need:

  • A Recraft API key, which you can obtain by:
    1. Registering an account on Recraft
    2. Going to your profile API page
    3. Purchasing API units (credits) and generating a key
  • An MCP client, such as Claude Desktop

Installing with Claude Desktop Extensions

If you're using Claude Desktop, this is the simplest setup method:

  1. Download the MCP Recraft Server extension from the latest release
  2. Double-click the downloaded file to open it with Claude Desktop
  3. Click "Install"
  4. Fill out the form with your Recraft API key
  5. Specify whether to store images locally or remotely
  6. Enable the server

If you encounter installation issues, verify you have the latest version of Claude Desktop.

Installing via Smithery

You can also find this MCP server on Smithery. Note that with Smithery installation, all generation results will be stored remotely. For local storage, use Desktop Extensions or manual setup instead.

Manual Setup from NPM

If you prefer a manual setup:

  1. Ensure Node.js is installed on your machine
  2. Modify your claude_desktop_config.json file to add the following:
{
  "mcpServers": {
    "recraft": {
      "command": "npx",
      "args": [
        "-y",
        "@recraft-ai/mcp-recraft-server@latest"
      ],
      "env": {
        "RECRAFT_API_KEY": "<YOUR_RECRAFT_API_KEY>",
        "IMAGE_STORAGE_DIRECTORY": "<YOUR_IMAGE_STORAGE_DIRECTORY>",
        "RECRAFT_REMOTE_RESULTS_STORAGE": "<YOUR_REMOTE_RESULTS_STORAGE_INDICATOR>"
      }
    }
  }
}

Manual Setup from Source

For installation from source:

  1. Clone the repository:
git clone https://github.com/recraft-ai/mcp-recraft-server.git
  1. Install dependencies and build:
npm install
npm run build
  1. Modify your claude_desktop_config.json file:
{
  "mcpServers": {
    "recraft": {
      "command": "node",
      "args": ["<ABSOLUTE_PATH_TO_CLONED_DIRECTORY>/dist/index.js"],
      "env": {
        "RECRAFT_API_KEY": "<YOUR_RECRAFT_API_KEY>",
        "IMAGE_STORAGE_DIRECTORY": "<YOUR_IMAGE_STORAGE_DIRECTORY>",
        "RECRAFT_REMOTE_RESULTS_STORAGE": "<YOUR_REMOTE_RESULTS_STORAGE_INDICATOR>"
      }
    }
  }
}

Configuration Parameters

For manual installation, you can use these parameters:

  • RECRAFT_API_KEY: Required - Your Recraft API key
  • IMAGE_STORAGE_DIRECTORY: Optional - Directory for storing generated images (default: $HOME_DIR/.mcp-recraft-server)
  • RECRAFT_REMOTE_RESULTS_STORAGE: Optional - Set to "1" to store images remotely and return URLs

Available Tools

The Recraft MCP Server provides several tools for image generation and manipulation:

Image Generation

  • generate_image: Creates raster/vector images from text prompts
    • Parameters: prompt, style, size, model, number of images
    • Price: $0.04/$0.08 per raster/vector image

Style Creation

  • create_style: Creates a custom style from image examples
    • Parameters: list of images, basic style
    • Price: $0.04

Image Conversion

  • vectorize_image: Converts raster images to vector format
    • Parameters: image
    • Price: $0.01

Image Editing

  • image_to_image: Generates new images based on an input image and prompt
    • Parameters: image, prompt, similarity strength, style, size, model, number of images
    • Price: $0.04/$0.08 per raster/vector image

Background Operations

  • remove_background: Removes the background from an image
    • Parameters: image
    • Price: $0.01
  • replace_background: Generates a new background from a prompt
    • Parameters: image, background prompt, style, size, model, number of images
    • Price: $0.04/$0.08 per raster/vector image

Image Enhancement

  • crisp_upscale: Sharpens and upscales an image
    • Parameters: image
    • Price: $0.004
  • creative_upscale: Creatively enhances and upscales an image
    • Parameters: image
    • Price: $0.25

User Information

  • get_user: Retrieves user information and remaining balance

For detailed explanations of these tools and their parameters, refer to the Recraft API documentation.

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 "recraft" '{"command":"npx","args":["-y","@recraft-ai/mcp-recraft-server@latest"],"env":{"RECRAFT_API_KEY":"<YOUR_RECRAFT_API_KEY>","IMAGE_STORAGE_DIRECTORY":"<YOUR_IMAGE_STORAGE_DIRECTORY>"}}'

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": {
        "recraft": {
            "command": "npx",
            "args": [
                "-y",
                "@recraft-ai/mcp-recraft-server@latest"
            ],
            "env": {
                "RECRAFT_API_KEY": "<YOUR_RECRAFT_API_KEY>",
                "IMAGE_STORAGE_DIRECTORY": "<YOUR_IMAGE_STORAGE_DIRECTORY>"
            }
        }
    }
}

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": {
        "recraft": {
            "command": "npx",
            "args": [
                "-y",
                "@recraft-ai/mcp-recraft-server@latest"
            ],
            "env": {
                "RECRAFT_API_KEY": "<YOUR_RECRAFT_API_KEY>",
                "IMAGE_STORAGE_DIRECTORY": "<YOUR_IMAGE_STORAGE_DIRECTORY>"
            }
        }
    }
}

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