Image to SVG

io.github.botmonsterPublished by GitHub account botmonsterv1.0.1Updated Oct 24, 2026

MCP server that converts raster images (PNG/JPG/WEBP) to SVG vector format

VerifiedSTDIODesktop onlyDeveloper ToolsMedia & Design

Overview

AI-generated overview

Converts raster images such as PNG, JPG, and WEBP into scalable SVG vector graphics, with tunable tracing parameters.

What you can do
Exposes a convert_image_to_svg tool that takes an image as base64 data or a URL and returns an SVG vector version. It supports PNG, JPG, JPEG, WEBP, TIFF and other common raster formats, and lets the caller control color mode, tracing mode, speckle filtering, color precision, layer merging, corner and splice thresholds, path precision, and curve-fitting iterations. It handles data URI prefixes automatically and streams URL downloads with a 5 MB size limit.
When to use it
Useful when an assistant needs to turn a generated or supplied raster image into a vector file, for example logos, icons, or stylized poster-style artwork. It fits workflows where the SVG output should be tuned for crisp edges, simplified colors, or noise removal rather than a default conversion.
Requirements
Runs as a local stdio process, typically launched with uvx image2svg-mcp, so a Python/uv runtime is needed. It can also run as an HTTP server via Docker on port 8000. No accounts, API keys, or environment variables are declared. Local file access requires the --allow-local-files-path flag.
Before you install
By default file:// URLs are rejected; enabling --allow-local-files-path grants access to files inside the specified directory and its subdirectories, so choose that path narrowly. Image URLs are fetched over the network, and remote downloads are capped at 5 MB. The server writes no data itself, but the resulting SVG should be reviewed before use.

Installation

In SourceWeft

  1. Open Image to SVG in the dashboard and add it to a workspace.
  2. Enable the server for the chats that should use its tools.

Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.

Other MCP clients

Follow the launch instructions in the repository.

README

image2svg-mcp

[PyPI] [Docker] [License] [Tests]

An MCP server that converts raster images (PNG, JPG, WEBP) to scalable SVG vector graphics.

Features

  • Accepts images as base64-encoded data or URL
  • Supports PNG, JPG, JPEG, WEBP, TIFF, and other common raster formats
  • Full control over vectorization parameters (color precision, speckle filtering, tracing mode, etc.)
  • Handles data:image/...;base64, URI prefixes automatically
  • Streams URL downloads with a 5 MB size limit
  • Optional file:// URL support for local images (opt-in via --allow-local-files-path)

Usage

To see it in action check converting image to svg online.

Claude Code & Claude Desktop

Add to your settings.json:

json
{  "mcpServers": {    "image2svg": {      "command": "uvx",      "args": ["image2svg-mcp"]    }  }}

for Claude Code add using command line:

bash
claude mcp add image2svg --scope user -- uvx image2svg-mcp

with access to local files:

bash
claude mcp add image2svg --scope user -- uvx image2svg-mcp --allow-local-files-path /home/user/images

Docker

Run as an HTTP server:

bash
docker run -p 8000:8000 ghcr.io/botmonster/image2svg-mcp

With local file access:

bash
docker run -p 8000:8000 -v /home/user/images:/images ghcr.io/botmonster/image2svg-mcp --allow-local-files-path /imagesclaude mcp add image2svg --transport http --scope user http://localhost:8000/mcp

This enables prompts like:

Convert this local file to SVG: file://logo.png

Only files inside the specified directory (and its subdirectories) are accessible. Paths are normalized to prevent directory traversal. Without this flag, file:// URLs are rejected.

Example Prompts

Here are some examples of what you can tell an LLM to do with this tool:

1. Simple image-to-SVG conversion

Generate an image of a sunset over mountains, then convert it to SVG.

The LLM will generate a raster image and then use the convert_image_to_svg tool with default settings to produce a clean vector version.

2. Fine-tuned conversion with specific parameters

Create a logo with a blue circle and a white star inside it. Now convert it to SVG using binary colormode for crisp edges and set filter_speckle to 10 to remove noise.

This uses colormode: "binary" for black/white line art style output, which works great for logos and icons. The higher filter_speckle value removes small artifacts.

3. Convert from URL with minimalist style

Convert this image to a simplified SVG with low color precision for a minimalist poster look: https://example.com/photo.png

Using color_precision: 3 reduces the number of colors dramatically, producing an artistic posterized vector effect. Great for stylized illustrations.

4. Convert a base64 image directly

Convert this base64 image to SVG: iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAO0lEQVR4nGP8z8Dwn4EIwESMIqwKGRn+MzBisYQJXRE2NopCbKYgi5Huxv8MjBiSyGJMuCTQNTJSPRwBCjYOD5JU5rIAAAAASUVORK5CYII=

This is a 10x10 red square with a blue circle in the middle. Useful for testing the tool with inline image data — no URL needed.

Tool Parameters

ParameterTypeDefaultRangeDescription
image_base64string--Base64-encoded image data. Provide this OR image_url.
image_urlstring--URL to fetch the image from (http://, https://, or file:// when enabled). Provide this OR image_base64.
colormodestring"color"color, binaryFull color or black/white line art
modestring"spline"spline, polygon, noneTracing mode: smooth curves, straight edges, or pixel-perfect
filter_speckleint40-128Remove speckles of N pixels or fewer
color_precisionint61-12Color quantization bits. Lower = fewer colors, simpler SVG
layer_differenceint160-128Color difference for merging layers
corner_thresholdint600-180Angle threshold for corner detection (degrees)
length_thresholdfloat4.03.5-10.0Minimum path segment length
splice_thresholdint450-180Angle threshold for splicing splines
path_precisionint81-12Decimal precision for SVG coordinates
hierarchicalstring"stacked"stacked, cutoutLayer arrangement mode
max_iterationsint101-100Max curve fitting iterations

Development

Installation

bash
git clone https://github.com/botmonster/image2svg-mcp.gitcd image2svg-mcpuv sync

Run tests

bash
uv run pytest tests/ -v

Run the MCP Inspector

bash
uv run fastmcp dev inspector src/image2svg_mcp/server.py:mcp

License

Apache 2.0 - see LICENSE

Source: README.md at commit 2c855cc

Tools

0
SourceWeft has not started this package in its sandbox yet, so its tools are not known.

Version history

1
  1. v1.0.1LatestSep 16, 2026

Score

50% of the applicable checks met

How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.

  • Reached in the last 30 days25 pts

    Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.

  • Auth declared10 pts

    Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.

  • Tools listed15 pts

    Answer tools/list without a credential, or ship a package that starts in a sandbox without one.

  • DescriptionRequired15 pts
  • Logo10 pts
  • Documentation15 pts
  • License10 pts