MCP Directory

How to add MCP Image Compression to Claude Desktop

High-performance MCP server for compressing JPEG, PNG, WebP and AVIF images offline. Paste the config into ~/Library/Application Support/Claude/claude_desktop_config.json and restart Claude Desktop.

Last updated June 14, 2026 ยท 33โ˜… ยท stdio ยท no auth

Claude Desktop config for MCP Image Compression

npx -y @inhiblab-core/mcp-image-compression
{
  "mcpServers": {
    "mcp-image-compression": {
      "command": "npx",
      "args": [
        "-y",
        "@inhiblab-core/mcp-image-compression"
      ],
      "env": {
        "IMAGE_COMPRESSION_DOWNLOAD_DIR": "<YOUR_DIR>"
      }
    }
  }
}

Setup steps

  1. 1Open Claude Desktop โ†’ Settings โ†’ Developer โ†’ Edit Config (this opens ~/Library/Application Support/Claude/claude_desktop_config.json).
  2. 2Paste the MCP Image Compression config below under the top-level "mcpServers" key.
  3. 3Fill in any placeholder secrets (API keys, paths) in the snippet.
  4. 4Save the file, then fully quit and reopen Claude Desktop.
  5. 5Open a chat and confirm MCP Image Compression's tools appear under the ๐Ÿ”Œ tools menu.

Before you start

  • Node.js with npx (to run the published @inhiblab-core/mcp-image-compression package)
  • An MCP-compatible client such as Claude Desktop, Cursor, or Windsurf
  • A writable local directory set via the IMAGE_COMPRESSION_DOWNLOAD_DIR environment variable
  • Optionally Docker, if building/running the server from the provided Dockerfile

What MCP Image Compression can do in Claude Desktop

image_compression

Compress one or more images. Inputs: urls (URLs of images to compress), quality (int, compression quality 0-100), and format (output format, e.g. "jpeg", "png", "webp", "avif"). Returns the URLs of the compressed images.

Security

No API key or authentication is required; the server runs locally over stdio and processes images offline. Set the IMAGE_COMPRESSION_DOWNLOAD_DIR environment variable to a directory where the server is allowed to write the compressed output files.

MCP Image Compression + Claude Desktop FAQ

Where is the Claude Desktop config file?

Claude Desktop reads MCP servers from ~/Library/Application Support/Claude/claude_desktop_config.json. Paste the MCP Image Compression config there under the "mcpServers" key and restart the client.

Is MCP Image Compression safe to use with Claude Desktop?

No API key or authentication is required; the server runs locally over stdio and processes images offline. Set the IMAGE_COMPRESSION_DOWNLOAD_DIR environment variable to a directory where the server is allowed to write the compressed output files.

Which image formats are supported?

The server supports JPEG, PNG, WebP, and AVIF for both input and output via the format parameter.

Does it require an internet connection or API key?

No. It works fully offline and requires no API key or authentication; compression runs locally.

Where are the compressed images saved?

Compressed files are written to the directory you set via the IMAGE_COMPRESSION_DOWNLOAD_DIR environment variable, and the tool returns the URLs of the compressed images.

View repo Full MCP Image Compression page