Skip to main content
Glama

gimp-mcp

Tell your AI assistant what you want, and watch it happen in GIMP. gimp-mcp connects Claude, Codex, Cursor, VS Code or any other MCP client to the GIMP window you already have open: it opens files, builds layers, sets editable text, makes selections, applies filters and exports, step by step, right in front of you.

PyPI Python CI License: MIT Linux macOS Windows

NOTE

Try 1.0.0rc1. 1.0.0 freezes the public API until 2.0, and its release candidate is out for at least three weeks of testing: uvx gimp-mcp@1.0.0rc1 setup installs it (the plain commands below keep installing the latest stable release). Tell us which tool, parameter, result or error should be named or shaped differently, which tool is missing, and how it runs on your platform, with a release-candidate report. Coming from 0.x: upgrading.

Quickstart

gimp-mcp runs on Linux, macOS and Windows. You need GIMP 3.2+, uv and an MCP client. On Ubuntu 26.04:

sudo apt install -y gimp python3-gi gir1.2-gimp-3.0   # GIMP 3.2+ (other distributions and Flatpak: see below)
uvx gimp-mcp setup                                    # installs the GIMP plug-in, adds the server to your MCP clients
uvx gimp-mcp doctor                                   # after (re)starting GIMP: every check should be [ok]

Then ask your assistant: "Use GIMP to create a 1280×720 image with the title 'Hello' and export it to ~/hello.png".

Related MCP server: GIMP MCP

Linux, macOS and Windows

The same package, the same uvx gimp-mcp setup, and the same tools on all three. Every change runs the full end-to-end suite against a real GIMP 3.2 on each of them, plus tests with GIMP's interface open, and each release is installed back from TestPyPI and PyPI and tested on all three.

Linux

macOS

Windows

Verified on

Arch, Ubuntu, Debian, Fedora, openSUSE, Alpine (x86_64)

macOS 15, Apple Silicon (arm64)

Windows Server 2025 (x86_64)

GIMP 3.2 from

your distribution, or Flathub

gimp.org (.dmg)

gimp.org (installer)

Bridge

Unix socket, 0600, peer uid checked

Unix socket, 0600, peer uid checked

named pipe, current user only

Tested in CI

✅ headless · ✅ with GIMP's interface

✅ headless · ✅ with GIMP's interface

✅ headless · ✅ with GIMP's interface

Exact versions and what differs per OS: compatibility.

Why gimp-mcp

Your GIMP, live. The assistant works in the GIMP you have open, not in a hidden copy. Every layer it adds shows up in the Layers panel, and you can take over with the mouse at any time.

Results you can keep editing. Titles stay editable text layers, each step can go on its own layer, blurs and color corrections can be editable filters, and the XCF keeps all of it. The assistant gives you a starting point, not a flattened PNG.

It checks its own work. Previews come back to the model as images, so it can see the result, fix what looks off and only then export. Checkpoints let it try an idea and go back to an earlier state when it doesn't work out.

Local and locked down. No network port: one Unix socket (a named pipe on Windows) that only you can open, a fresh token at every GIMP start, a fixed set of operations, and an allowlist for the GIMP procedures it may call (no eval, no Script-Fu passthrough). Details in the security model.

Set up in one command. gimp-mcp setup finds GIMP (distribution package, Flatpak, or gimp.org's app on macOS and Windows), installs the plug-in and adds the server to Claude Code, Claude Desktop, VS Code and Cursor, asking before it changes any file.

Things to ask

  • "Open ~/Pictures/team.jpg, crop it to a centered square and export a 512 px avatar."

  • "Make a 1200×630 social card for my blog post 'Shipping on Fridays', dark background, title on the left."

  • "Brighten only the background layer of poster.xcf and keep the original underneath, hidden."

  • "What's in ~/design/flyer.xcf? List the layers, the hidden ones and the fonts used."

  • "Blur the license plate in car.jpg and save a copy next to it."

Use cases

Typical GIMP jobs done end to end through MCP, each with a scripted version checked in CI on Linux, macOS and Windows, and an agent version (one plain-language request) in the evaluation suite:

  • Restore an old scanned photo: straighten, crop the scanner bed, heal dust and scratches, restore contrast, reduce grain, 16-bit TIFF for print (walk-through).

  • Product photo for an online store: cut out without losing pixels, soft shadow on pure white, centered square, JPEG and WebP in three sizes with an sRGB profile (walk-through).

  • Social media kit: one design in four formats (post, story, banner, thumbnail) with safe-area guides and an editable headline (walk-through).

  • Tutorial screenshot: callouts and arrows, private data pixelated beyond recovery, metadata removed (walk-through).

  • Photos for a website: a folder upright, resized, watermarked, GPS removed, WebP and JPEG, the corrupt file reported (walk-through).

  • Animated sticker: frames with timing and disposal, optimized GIF and animated WebP under a size budget (walk-through).

  • Print-ready flyer: A5 at 300 dpi with bleed, trim and safe-margin guides, PDF and TIFF at print size (walk-through).

  • Sky replacement: a new sky masked in, the foreground graded with an editable filter, no halo (walk-through).

  • YouTube thumbnail from one photo, with an editable title (guide).

What it can do

Look

list open images, inspect layer trees and items, render previews the model can see

Files

create, open, save XCF, export PNG and JPEG with options, close

Layers

add, import, duplicate, group, reorder, rename, opacity, blend modes, visibility

Shape

resize image or canvas, crop, scale, rotate, flip, move

Select

rectangles and ellipses (add, subtract, intersect, feather), invert, layer masks

Paint

fills, lines and paths, rectangles and ellipses

Text

editable text layers: font, size, color, alignment, spacing

Adjust

brightness/contrast, hue/saturation, blur, as destructive or editable filters

History

undo groups (one Ctrl+Z in GIMP) and checkpoints the assistant can restore

Everything else

about 420 more GIMP procedures, allowlisted (procedures toolset, opt-in)

159 tools in all (49 enabled by default), grouped into toolsets so your client only loads what it needs: see the tool reference and the coverage matrix.

How it works

 Claude / Codex / Cursor / …            gimp-mcp serve                 GIMP 3.2
 ───────────────────────────  MCP   ─────────────────────  Unix socket  ──────────────────────────
  "make the colors pop"      stdio   validates, maps ids  (named pipe   gimp-mcp-bridge plug-in
                            ──────▶  to GIMP operations   on Windows)   runs them in your session
                                                         ────────────▶

gimp-mcp setup copies a small Python plug-in into your GIMP profile. GIMP starts it with the application, and it serves its local socket while GIMP runs. The MCP server (uvx gimp-mcp serve, started by your client) talks to it. Also works with a headless GIMP for scripts and CI. More in the architecture notes.

Documentation

Also listed in the official MCP registry as io.github.mhbxyz/gimp-mcp. MIT licensed.

Available Tools

49 tools
gimp_add_layer_maskAdd layer maskA

Add a mask to a layer or group. fill: 'white' (everything visible), 'black' (everything hidden), 'alpha' (from the layer's transparency), 'selection' (selected = visible; EMPTY_SELECTION if nothing is selected), 'grayscale' (from the layer's luminance). invert inverts it. Non-destructive: the layer's pixels are kept. One undo step.

Inputs: item (required), fill, invert. Returns: x, y, id, kind, +11 more

gimp_brightness_contrastBrightness / contrastA
Destructive

Adjust brightness and contrast of a layer, each from -100 to 100 (0 = unchanged; GIMP's -1..1 curve, not a percentage: on mid-gray 128, brightness -30 gives 119 (7% darker), -100 gives 92; contrast pivots on light gray, +30 turns 128 into 54). For 'N% darker/lighter' use gimp_hue_saturation lightness -N/+N. One undo step.

Inputs: item (required), contrast, brightness, destructive. Returns: id, item, filter, operation, +2 more

gimp_close_imageClose imageA
Destructive

Close an image. Refused with UNSAVED_CHANGES when it has unsaved changes, unless discard_changes=true. Its id (and its items' ids) become invalid. Not undoable: the image and its undo history are gone.

Inputs: image (required), discard_changes. Returns: image, closed

gimp_create_checkpointCreate checkpointA

Keep a full copy of the image's current state (layers, text, masks, filters, selection) so it can be restored later: this is how to undo/redo. Copies are hidden from image lists and use memory; at most 20 per image.

Inputs: image (required), label. Returns: image, label, width, height, +2 more

gimp_create_groupCreate layer groupB

Add an empty layer group at an explicit parent and position. One undo step.

Inputs: name (required), image (required), parent, position. Returns: x, y, id, kind, +11 more

gimp_create_imageCreate imageA

Create a new image with a single layer named layer_name filled with an explicit color (default white; 'transparent' gives an alpha layer). Like a new image in GIMP's UI, it starts without unsaved changes and without undo history. Shown in a window when GIMP has a UI.

Inputs: width (required), height (required), fill, base_type, +2 more. Returns: id, file, name, dirty, +5 more

gimp_create_layerCreate layerB

Add a new raster layer (with alpha) to an image, at an explicit parent and position. Size and offset are in image pixels (default: the image size at 0,0). fill: 'transparent' or a color. One undo step.

Inputs: name (required), image (required), x, y, +8 more. Returns: x, y, id, kind, +11 more

gimp_create_text_layerCreate text layerA

Add an editable text layer. Position (x, y) is the top-left corner in image pixels. size is in size_unit ('px' or 'pt'). Without box_width/box_height the layer grows with the text; with both, the text wraps in a fixed box. The text stays editable (never rasterized). One undo step. Rich text, outlines, vertical text: gimp_set_text_style (toolset typography).

Inputs: text (required), image (required), x, y, +12 more. Returns: x, y, id, kind, +11 more

gimp_crop_imageCrop imageA
Destructive

Crop the image to the rectangle (x, y, width, height) in image pixels, which must lie inside the canvas. Destructive: layer pixels outside the rectangle are discarded. One undo step.

Inputs: x (required), y (required), image (required), width (required), +1 more. Returns: id, dirty, image, width, +1 more

gimp_delete_checkpointDelete checkpointA
Destructive

Free a checkpoint's memory. Closing an image deletes its checkpoints too. Checkpoints are not in GIMP's undo history.

Inputs: checkpoint (required). Returns: deleted, checkpoint

gimp_delete_layerDelete layerA
Destructive

Remove a layer or a group with all its children. Destructive: the pixels are lost unless undone in GIMP or the image is reverted from a saved file. Ids of removed items become invalid.

Inputs: item (required). Returns: item, deleted

gimp_draw_pathDraw line / polylineA
Destructive

Stroke a polyline through points [[x, y], ...] (image pixels, at least 2 points) with a plain line of the given width, color and opacity; closed=true joins the last point to the first. Uses a solid line, never the user's brush. Points outside the layer are clipped. One undo step.

Inputs: item (required), color (required), points (required), cap, +5 more. Returns: id, item, changed, affected

gimp_draw_shapeDraw rectangle / ellipseA
Destructive

Draw a rectangle or an ellipse (inscribed in x, y, width, height) on a layer, filled with fill_color and/or outlined with stroke_color (stroke centered on the outline). The image's selection is left unchanged. One undo step.

Inputs: x (required), y (required), item (required), shape (required), +7 more. Returns: id, item, changed, affected

gimp_duplicate_layerDuplicate layerA

Copy a layer or a whole group (with masks and children). By default the copy is placed just above the original in the same parent. GIMP names it ' copy'. One undo step.

Inputs: item (required), parent, position. Returns: x, y, id, kind, +11 more

gimp_enable_toolsetsEnable toolsetsA

Add the tools of one or more toolsets (see gimp_list_toolsets) to your tool list for this session. The result gives each added tool's signature (usage): call them with those arguments. The server notifies the client that its tool list changed; a client that does not refresh its tool list needs a restart with the toolsets in --toolsets or GIMP_MCP_TOOLSETS. Images and their undo history are untouched.

Inputs: toolsets (required). Returns: usage, enabled, added_tools

gimp_export_imageExport PNG/JPEGA
Destructive

Export the visible composite of the image to PNG or JPEG (format from the extension). The image itself is not modified. Existing files are only replaced when overwrite=true. Defaults: PNG compression 9, not interlaced; JPEG quality 90, baseline, optimized, transparency flattened on white. WebP, AVIF, TIFF, PDF…: gimp_export_as (toolset formats). The undo history is unchanged.

Inputs: path (required), image (required), format, overwrite, +2 more. Returns: path, bytes, image, width, +3 more

gimp_fillFillA
Destructive

Fill a layer (or layer mask) with a solid color. area='selection' fills the selected part only (EMPTY_SELECTION if nothing is selected); area='layer' fills the whole layer and ignores (but keeps) the selection. Destructive for the pixels it covers. One undo step.

Inputs: item (required), color (required), area, mode, +1 more. Returns: id, item, changed, affected

gimp_flip_layerFlip layerA

Mirror a layer or group horizontally or vertically around its center. Lossless. One undo step.

Inputs: item (required), direction (required). Returns: x, y, id, kind, +11 more

gimp_gaussian_blurGaussian blurA
Destructive

Blur a layer with a Gaussian of standard deviation radius pixels (radius_y defaults to radius). One undo step. Any other GEGL filter: gimp_apply_filter (toolset effects).

Inputs: item (required), radius (required), radius_y, destructive. Returns: id, item, filter, operation, +2 more

gimp_get_selectionGet selectionB
Read-only

Whether the image has a selection, its bounds, and optionally whether a point is selected.

Inputs: image (required), probe_x, probe_y. Returns: id, empty, image, bounds, +1 more

gimp_hue_saturationHue / saturationA
Destructive

Rotate hue (degrees, -180..180) and change saturation and lightness (-100..100, 0 = unchanged) of a layer, for all colors or one hue range. Lightness is proportional: -30 makes it 30% darker (mid-gray 128 -> 90), +30 goes 30% of the way to white (128 -> 166). One undo step. Levels, curves, exposure…: gimp_levels (toolset color).

Inputs: item (required), hue, overlap, hue_range, +3 more. Returns: id, item, filter, operation, +2 more

gimp_import_layerImport file as layerA

Load an image file (PNG, JPEG, XCF... absolute path) as a new layer of an existing image. Multi-layer files are flattened into one layer. Placed at x,y (default 0,0); name defaults to the file name. One undo step.

Inputs: path (required), image (required), x, y, +3 more. Returns: x, y, id, kind, +11 more

gimp_inspect_imageInspect imageA
Read-only

Describe one image: size, mode, precision, resolution, unsaved changes, associated files and the full ordered layer tree (groups, children, masks, offsets, opacity, blend mode, locks). Does not depend on GIMP's active selection.

Inputs: image (required). Returns: id, file, name, unit, +12 more

gimp_inspect_itemInspect itemA
Read-only

Describe one item by id: kind (layer, group, text, mask, channel, path), owning image, parent and position, and its layer properties. Fails with NOT_FOUND once the item is deleted.

Inputs: item (required). Returns: x, y, id, kind, +13 more

gimp_inspect_textInspect text layerC
Read-only

Text, font, size and unit, color, justification, spacing, antialiasing and geometry.

Inputs: item (required). Returns: x, y, font, item, +10 more

gimp_list_checkpointsList checkpointsC
Read-only

Checkpoints of an image, oldest first.

Inputs: image (required). Returns: image, checkpoints

gimp_list_filtersList editable filtersC
Read-only

Editable (non-destructive) filters attached to a layer.

Inputs: item (required). Returns: id, item, filters

gimp_list_fontsList fontsB
Read-only

Fonts GIMP knows (fontconfig names), filtered by a substring.

Inputs: limit, query. Returns: fonts, total

gimp_list_toolsetsList toolsetsA
Read-only

List the groups of GIMP tools (toolsets), what each contains and which are enabled. Tools of disabled toolsets are not in your tool list: enable them with gimp_enable_toolsets.

Inputs: no named parameters. Returns: toolsets

gimp_modify_selectionSelect all / none / invertA

'all' selects the whole canvas, 'none' clears the selection, 'invert' inverts it. One undo step.

Inputs: image (required), action (required). Returns: id, empty, image, bounds, +1 more

gimp_move_layerMove layer in the stackA

Move a layer or group to another parent (a group of the same image, or null for the top level) and position (0 = top-most). Does not change pixels or offsets. One undo step.

Inputs: item (required), parent (required), position (required). Returns: x, y, id, kind, +11 more

gimp_open_imageOpen imageA

Open a local file (XCF or any format GIMP can load: PNG, JPEG, WebP, TIFF...) as a new image. The path must be absolute (~ allowed). PDF pages, SVG size, RAW: gimp_open_with_options (toolset formats). A new image: nothing in an undo history changes.

Inputs: path (required). Returns: id, file, name, dirty, +5 more

gimp_previewPreview imageA
Read-only

Render the composite of an image (all visible layers, with transparency) as a PNG whose longest side is at most max_size pixels (16-1024, default 512 or $GIMP_MCP_PREVIEW_MAX_SIZE). Proportions are kept and the image is never upscaled. Does not modify the document, its undo history or its saved state.

Inputs: image (required), max_size. Returns: bytes, image, scale, width, +5 more

gimp_remove_filterRemove editable filterA

Remove an editable filter from a layer: the layer renders as if it had never been applied. One undo step.

Inputs: item (required), filter (required). Returns: id, item, filters

gimp_remove_layer_maskRemove layer maskA
Destructive

Remove a layer's mask. mode='apply' bakes it into the layer's alpha (destructive: hidden pixels become transparent); mode='discard' drops it (the layer is shown unmasked). One undo step.

Inputs: item (required), mode (required). Returns: x, y, id, kind, +11 more

gimp_resize_canvasResize canvasA

Change the canvas size without resampling. Layers move by (offset_x, offset_y) and keep their size, unless resize_layers is 'all' or 'image-sized' (layers that covered the old canvas): those grow or shrink to the canvas, new areas transparent or fill_color. One undo step.

Inputs: image (required), width (required), height (required), offset_x, +3 more. Returns: id, dirty, image, width, +1 more

gimp_resize_imageScale imageA
Destructive

Scale the whole image and every layer to width x height pixels (layer sizes and offsets scale proportionally). Give only width or only height to keep the aspect ratio. Lossy: pixels are resampled with the given interpolation. One undo step.

Inputs: image (required), width, height, interpolation. Returns: id, dirty, image, width, +1 more

gimp_restore_checkpointRestore checkpoint (undo/redo)A
Destructive

Replace the image with the state saved in a checkpoint. The restored image gets a NEW image id and new item ids (the old ones become invalid); GIMP windows showing it are reconnected; its file association is kept and it is marked as having unsaved changes; its GIMP undo history starts empty. Checkpoints are kept, so restoring a later one redoes. Destructive for the current state unless it was checkpointed.

Inputs: image (required), checkpoint (required). Returns: id, file, name, dirty, +7 more

gimp_rotate_imageRotate imageA
Destructive

Rotate the whole image (canvas, layers, selection, paths) by 90, 180 or 270 degrees clockwise. Lossless. One undo step.

Inputs: angle (required), image (required). Returns: id, dirty, image, width, +1 more

gimp_rotate_layerRotate layerA
Destructive

Rotate a layer or group by angle degrees (clockwise) around its center. clip='adjust' grows the layer to keep all pixels, 'clip' keeps the original bounds. Multiples of 90 are lossless with interpolation 'none'; other angles resample. One undo step. Perspective, shear: gimp_transform (toolset geometry).

Inputs: item (required), angle (required), clip, interpolation. Returns: x, y, id, kind, +11 more

gimp_save_imageSave project (XCF)A
Destructive

Save the image as a GIMP project (.xcf), keeping layers, groups, masks and text. Without path, saves to the image's current XCF file (a normal 'Save'). With a path, an existing file is only replaced when overwrite=true. Marks the image as having no unsaved changes. Writing the file is not in GIMP's undo history.

Inputs: image (required), path, overwrite. Returns: bytes, dirty, image, xcf_file

gimp_scale_layerScale layerA
Destructive

Resample a layer or group to width x height pixels; give only width or only height to keep its aspect ratio. anchor='center' keeps its center, 'top-left' keeps its top-left corner. Lossy. One undo step.

Inputs: item (required), width, anchor, height, +1 more. Returns: x, y, id, kind, +11 more

gimp_select_ellipseSelect ellipseA

Select the ellipse inscribed in the rectangle (x, y, width, height), antialiased, combined with the current selection. One undo step. By color or magic wand: gimp_select_by_color (toolset channels).

Inputs: x (required), y (required), image (required), width (required), +3 more. Returns: id, empty, image, bounds, +1 more

gimp_select_rectangleSelect rectangleB

Select a rectangle (image pixels, origin top-left) combined with the current selection. The part outside the canvas is ignored. Selections are part of the image (undoable, saved in XCF).

Inputs: x (required), y (required), image (required), width (required), +3 more. Returns: id, empty, image, bounds, +1 more

gimp_set_layer_maskConfigure layer maskB

apply: whether the mask affects the rendering (disable to see the layer unmasked); show: display the mask itself; edit: make painting tools target the mask. One undo step.

Inputs: item (required), edit, show, apply. Returns: x, y, id, kind, +11 more

gimp_set_layer_offsetsMove layer (offsets)A

Place a layer or group so its top-left corner is at (x, y) in image pixels (may be negative or outside the canvas). Lossless. Refused with LOCKED when its position is locked. One undo step.

Inputs: x (required), y (required), item (required). Returns: x, y, id, kind, +11 more

gimp_set_layer_propertiesSet layer propertiesA

Rename a layer or group and/or change its visibility, opacity (0-100), blend mode or locks (content, position, visibility, alpha). Only the given properties change. Not destructive: pixels are untouched. One undo step.

Inputs: item (required), mode, name, opacity, +5 more. Returns: x, y, id, kind, +11 more

gimp_set_textEdit text layerA

Change the text, font, size, color, justification, spacing, box or position of an existing text layer; only given properties change. Refused with WRONG_KIND on non-text layers and with FONT_NOT_FOUND (nothing changed) for unknown fonts. One undo step.

Inputs: item (required), x, y, font, +10 more. Returns: x, y, id, kind, +11 more

gimp_statusGIMP statusA
Read-only

Diagnose the connection to the running GIMP session: GIMP version, session id and the list of open images (with their ids). Call this first.

Inputs: no named parameters. Returns: images, socket, connected, session_id, +6 more

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.4/5.0

    Scored across 49 tools

    Disambiguation4/5

    Most tools target clearly distinct resources and actions, with descriptions that resolve likely confusion. Minor overlaps remain between move_layer and set_layer_offsets, fill and draw_shape, and status versus inspect_image, but these are manageable.

    Naming Consistency4/5

    The tool set uses a consistent gimp_ prefix and snake_case throughout. Most names follow verb_noun, though a few are effect or noun names such as gimp_status, gimp_brightness_contrast, and gimp_gaussian_blur.

    Tool Count2/5

    At 49 tools, the surface is very heavy for an agent and exceeds the typical well-scoped range. The toolsets mechanism mitigates this, but the presented set still feels over-large and requires careful grouping.

    Completeness4/5

    Coverage is strong for image, layer, group, selection, mask, text, save/export, and checkpoint workflows. Some common GIMP operations such as merge/flatten, freehand painting, transforms, and broader filter application are absent or only referenced via other toolsets.

    Maintenance

    ActivityNo data
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      B
      maintenance
      Enables AI agents to operate GIMP 3 end-to-end: open and inspect images, call every PDB procedure, apply GEGL filters destructively or as layer effects, measure pixels, render before/after/diff comparisons, cut out subjects with AI segmentation, and run multi-step recipes across folders.
      32
      54 PyPI
      5
      Apache 2.0
    • A
      license
      C
      quality
      B
      maintenance
      Enables AI agents to perform structured, semantic artwork editing in GIMP 3 through session-based tools for layers, selections, text, transforms, non-destructive filters, previews, and image export, backed by snapshot undo/redo and XCF-persisted sessions. It also offers a live control center and operation event timeline for observing and managing edits, plus PDB search for expert discovery.
      61
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables AI assistants to create, paint, edit, inspect, and export images in a running GIMP 3.2 instance via MCP.
      130 PyPI
      GPL 3.0
    • A
      license
      B
      quality
      C
      maintenance
      Enables AI agents to drive GIMP 3 over MCP, covering layers, selections, painting, text, color adjustments, GEGL filters, raw PDB procedures, and free-form Python inside GIMP, with image previews so the agent can see the result of each step. It installs its bridge plugin automatically and launches or attaches to a running GIMP instance, which stays open across MCP client restarts.
      42
      MIT