Get the FREE Ultimate OpenClaw Setup Guide →

mcp-recraft

MCP (modelcontextprotocol) server implementation for Recraft API

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio recraft-ai-mcp-recraft-server npx -y @recraft-ai/mcp-recraft-server@latest \
  --env RECRAFT_API_KEY="<YOUR_RECRAFT_API_KEY>" \
  --env IMAGE_STORAGE_DIRECTORY="<YOUR_IMAGE_STORAGE_DIRECTORY>" \
  --env RECRAFT_REMOTE_RESULTS_STORAGE="<YOUR_REMOTE_RESULTS_STORAGE_INDICATOR>"

How to use

This MCP server integrates Recraft’s image generation and editing capabilities with your MCP client. It exposes tools for creating raster and vector images from prompts, editing images, vectorizing raster images, and performing advanced operations such as background removal and replacement, upscaling, and style creation. The available tools include generate_image (prompt-based generation), create_style (builds a style from given images), vectorize_image (convert raster to vector), image_to_image (generate images conditioned on an existing image and a prompt), remove_background (remove backgrounds), replace_background (add a new background from a prompt), crisp_upscale (high-quality upscaling), creative_upscale (alternative upscale), and get_user (retrieve user info and balance). To use these tools via your MCP client, configure the recraft MCP server in your Claude Desktop setup or via your chosen environment, supply your Recraft API key, and specify storage behavior (local directory or remote storage) as described in the setup instructions.

How to install

Prerequisites:

  • Node.js installed on your machine (required to use npx or node commands).
  • Access to a terminal/command prompt.
  • A Recraft API key (for generating and manipulating images).

From NPM (quick setup):

  1. Ensure Node.js is installed.
  2. In Claude Desktop, modify claude_desktop_config.json to add the recraft server entry:
{
  "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>"
      }
    }
  }
}
  1. Save the file and run the MCP server through Claude Desktop or your environment, which will launch npx to install and start the server.

From Source:

  1. Clone the repository and install dependencies:
git clone https://github.com/recraft-ai/mcp-recraft-server.git
cd mcp-recraft-server
npm install
npm run build
  1. Start or integrate the built server via your MCP client configuration (as shown above), pointing to the built dist/index.js:
{
  "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>"
      }
    }
  }
}
  1. Ensure the required environment variables are set as described: RECRAFT_API_KEY (mandatory), IMAGE_STORAGE_DIRECTORY (optional, defaults to $HOME/.mcp-recraft-server if remote results storage is not enabled), and RECRAFT_REMOTE_RESULTS_STORAGE (optional, set to "1" to store results remotely.

Additional notes

Notes and tips:

  • RECRAFT_API_KEY is mandatory for all image generation tasks.
  • IMAGE_STORAGE_DIRECTORY controls local storage of generated images unless RECRAFT_REMOTE_RESULTS_STORAGE is enabled.
  • If RECRAFT_REMOTE_RESULTS_STORAGE is set to "1", local storage is ignored and remote URLs are returned instead.
  • When using Claude Desktop Extensions, you can install via mcp-recraft-server.dxt from the latest release for a streamlined setup.
  • If you encounter issues, ensure Node.js is up to date and that you have the latest Claude Desktop and the Recraft API key active.
  • The server pricing aligns with Recraft’s tool usage; each tool has per-image cost as shown in the Tools table.

Related MCP Servers

Sponsor this space

Reach thousands of developers