Pic2Vector MCP — Image to SVG for AI assistants
The MCP server for Pic2Vector, the free in-browser image-to-SVG converter.
[npm version]
[license]
[Try online]
[Terminal demo: vectorize_image turns a PNG into an SVG]
Scripted terminal demo of the stdio server (about 12 seconds). It shows tools/list, a vectorize_image call, and the SVG that was written. It is not a recording inside Claude Desktop or Cursor.
pic2vector-mcp runs locally over stdio. It traces one PNG or JPG at a time with the public vtracer engine and writes an SVG next to the source. No account, no upload, no telemetry.
Quick start
Requires Node.js 18 or newer.
Claude Desktop
Add this to claude_desktop_config.json (~/Library/Application Support/Claude/ on macOS, %APPDATA%\Claude\ on Windows):
Claude Code
Cursor
[Install in Cursor]
Or merge this into ~/.cursor/mcp.json (global) or .cursor/mcp.json (this project):
VS Code
Create .vscode/mcp.json:
Then ask the assistant to convert a file, for example: “Convert logo.png to SVG”.
Tool reference
One tool: vectorize_image.
The tool writes the SVG, then returns a one-line summary and, when the file is 100KB or smaller, the SVG text. The file starts with <!-- Generated by pic2vector-mcp · https://pic2vector.com -->.
color uses vtracer's photo preset (color, spline, stacked). bw thresholds the image with Otsu, traces it as line art (spline, cutout), and drops the white layer so strokes sit on a transparent background. The long edge is scaled to at most 2048 pixels before tracing.
Want better results?
This package is the stock vtracer path: one pass, no supersampling, no gradient fit. Open the image to SVG converter when you want the studio tools.
Privacy
The server runs on your machine. A local file never leaves the disk. A URL is downloaded only to trace it, then discarded. Nothing is sent to Pic2Vector. The same commitment is spelled out at https://pic2vector.com/privacy/.
Develop
npm test packs the tarball and drives vectorize_image over stdio. The published command is npx -y pic2vector-mcp.
Credits
Built by Pic2Vector · Engine: vtracer (MIT)