Krita MCP - Paint with Claude
An MCP server that lets Claude paint in Krita. Paint, see the result, adjust, repeat.
How It Works
- A Krita plugin runs an HTTP server inside Krita
- An MCP server bridges Claude to that plugin
- Claude can create canvases, set colors, paint strokes, and export to see results
Installation
Step 1: Install the Krita Plugin
Find your Krita resources folder:
- Windows:
%APPDATA%\krita\pykrita\ - Mac:
~/Library/Application Support/krita/pykrita/ - Linux:
~/.local/share/krita/pykrita/
Copy the plugin files:
krita_plugin/kritamcp.desktop -> [resources]/pykrita/kritamcp.desktop
krita_plugin/kritamcp/ -> [resources]/pykrita/kritamcp/
On Windows, that's:
C:\Users\[YOU]\AppData\Roaming\krita\pykrita\kritamcp.desktop
C:\Users\[YOU]\AppData\Roaming\krita\pykrita\kritamcp\__init__.py
Enable the plugin in Krita:
- Open Krita
- Go to Settings > Configure Krita > Python Plugin Manager
- Find "Krita MCP Bridge" and enable it
- Restart Krita
Verify it's working:
- Open Krita
- The plugin starts an HTTP server on port 5678
- Test: Open browser to
http://localhost:5678/health - Should see:
{"status": "ok", "plugin": "kritamcp"}
Step 2: Add the MCP Server
For Claude Code:
claude mcp add krita-mcp -- uv run --with fastmcp --with httpx fastmcp run /path/to/server.py
For Claude Desktop (add to config):
{
"mcpServers": {
"krita-mcp": {
"command": "uv",
"args": ["run", "--with", "fastmcp", "--with", "httpx", "fastmcp", "run", "/path/to/server.py"]
}
}
}
Tools
| Tool | Description |
|---|---|
krita_health |
Check if Krita is running with plugin |
krita_new_canvas |
Create new canvas (size, background color) |
krita_set_color |
Set paint color (hex) |
krita_set_brush |
Set brush preset, size, opacity |
krita_stroke |
Paint a stroke through points |
krita_fill |
Fill area at point |
krita_draw_shape |
Draw rectangle, ellipse, or line |
krita_get_canvas |
Export canvas to PNG, return path |
krita_undo |
Undo last action |
krita_redo |
Redo |
krita_clear |
Clear canvas to color |
krita_save |
Save to specific path |
krita_get_color_at |
Sample color at pixel |
krita_list_brushes |
List available brush presets |
Example Session
Claude: krita_new_canvas(800, 600, "Evening Sky", "#1a1a2e")
-> Created canvas: 800x600, background: #1a1a2e
Claude: krita_set_color("#b8a9c9")
-> Color set to #b8a9c9
Claude: krita_set_brush("Soft", 30)
-> Brush set: preset=Soft, size=30
Claude: krita_stroke([[100, 300], [200, 280], [300, 290], [400, 270]])
-> Stroke painted with 4 points
Claude: krita_get_canvas("sky_v1.png")
-> Canvas saved to: ~/krita-mcp-output/sky_v1.png
Claude: [views image, decides to adjust]
Claude: krita_undo()
-> Undone
Claude: krita_set_brush("Soft", 50, 0.5)
Claude: krita_stroke([[100, 300], [200, 285], [300, 290], [400, 275]])
The Creative Loop
- Paint - Use stroke, shape, fill commands
- Export -
krita_get_canvas()saves current state - View - Read the PNG file to see what was painted
- Adjust - Undo, change settings, paint more
- Repeat
This is different from code-based art. You're actually painting and seeing and responding to your own work.
Configuration
The plugin saves exports to ~/krita-mcp-output/ by default. Edit CANVAS_OUTPUT_DIR in krita_plugin/kritamcp/__init__.py to change this.
The HTTP server runs on port 5678 by default. Edit SERVER_PORT in the same file to change this.
Troubleshooting
"Cannot connect to Krita"
- Make sure Krita is running
- Check that the plugin is enabled (Settings > Configure Krita > Python Plugin Manager)
- Verify HTTP server:
http://localhost:5678/health
Plugin doesn't appear in Krita
- Check file locations match exactly
- Make sure
kritamcp.desktopis in pykrita folder (not inside kritamcp subfolder) - Restart Krita after copying files
Commands timeout
- Krita might be busy with another operation
- Try again after a moment
- Check Krita's Python console for errors (Settings > Dockers > Log Viewer)
License
MIT
Metadata
Release files for iflow-mcp_maryfellowes-krita-mcp 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| iflow_mcp_maryfellowes_krita_mcp-0.1.0.tar.gz | 10.9 kB | Without provenance | Details for iflow_mcp_maryfellowes_krita_mcp-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| iflow_mcp_maryfellowes_krita_mcp-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for iflow_mcp_maryfellowes_krita_mcp-0.1.0-py3-none-any.whl |
Total release size: 29.5 kB
Release files / iflow_mcp_maryfellowes_krita_mcp-0.1.0.tar.gz
| Download URL | iflow_mcp_maryfellowes_krita_mcp-0.1.0.tar.gz |
|---|---|
| Size | 10.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
57f5fb98ad6d627e8d11a92f56a8c207753fa94c6002c5a36a61d89102709afb
|
|
BLAKE2b-256 checksum How to use checksums |
937a2d04324b95ead293fced731a52612bccd95761d76b97db5fd75ce7a43ac7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.0 {"installer":{"name":"uv","version":"0.10.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / iflow_mcp_maryfellowes_krita_mcp-0.1.0-py3-none-any.whl
| Download URL | iflow_mcp_maryfellowes_krita_mcp-0.1.0-py3-none-any.whl |
|---|---|
| Size | 18.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3c4fcf02bafc72a92de3c88bd908c087435f011abfb075e6342965af778b9011
|
|
BLAKE2b-256 checksum How to use checksums |
fb6dae5ed7af60675738728939b194f9bae4cc1f8e63f549ae8e70524425015b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.0 {"installer":{"name":"uv","version":"0.10.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for iflow-mcp_maryfellowes-krita-mcp 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.