prusaslicer-mcp
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
prusaslicer-mcp
An MCP server that lets Claude (or any MCP client) drive the PrusaSlicer 2.9.x command line: discover installed printers and profiles, sanity-check and look at a model, work out which way up to print it, slice it headlessly with your real presets, and get print time and filament use back.
It runs PrusaSlicer as a separate process, so it works while the GUI is open and does not touch it. It does not control the GUI itself (PrusaSlicer 2.9.x has no remote-control API), and it targets 2.9.x only; PrusaSlicer 3.x is not supported yet.
Status: early. Seven tools, tested against PrusaSlicer 2.9.7 on macOS and Windows. See the roadmap.
An independent project. It is not affiliated with, endorsed by or supported by Prusa Research. PrusaSlicer and Prusa are trademarks of Prusa Research a.s.
Example
Once registered with an MCP client, you can ask things like:
"Which printers do I have installed? Check
~/models/bracket.stland slice it on the MINI with Prusament PLA at 0.20mm, 25% infill. How long will it take and how much filament does it use?"
Behind that, the client calls list_printers → list_profiles → inspect_model → slice_model and
reads back the print time and filament use. preview_model and preview_gcode let it look at the model and at what was sliced, and suggest_orientation proposes which way up to print.
A scan that will not slice is a different conversation:
"
~/scans/statue.stlwon't slice. What's wrong with it, and which way up should I print it?"
Behind that: inspect_model reports an open base, suggest_orientation with close_holes finds the orientation that stands the capped base flat on the bed (and, given your profiles, measures what the supports would cost in each), preview_model shows it before anything is sliced, and slice_model prints it.
Related MCP server: orcaslicer-mcp
Tools
Tool | What it does |
| Installed printer models, exact printer profile names, nozzle variants, bed sizes |
| Print (quality) profiles and compatible filament profiles for a printer profile |
| Size, volume, watertightness, open holes (and how many are flat gaps |
| Slice with |
| Ranks the ways to stand a model: its large flat faces, the axes and the orientation as stored, each with the |
| A PNG of a model from iso, front, side or top, or all four on one sheet, with its size and which way is up; shows a Y-up scan lying on its side at a glance. Takes the same |
| A PNG of sliced G-code: one layer's toolpaths coloured by feature, or front and side silhouettes of everything printed, where an empty stretch shows as a blank band |
Profile names must match exactly; use list_printers and list_profiles to discover them.
Projects. A 3MF saved from PrusaSlicer carries its own settings (supports, brim, infill...). Slice it with no profiles to keep them; passing profiles makes PrusaSlicer ignore them and use the plain profile values (ADR 0007). inspect_model shows what a project saves.
G-code is always written as text (--binary-gcode=0) so statistics can be read back.
Install
Requires Python 3.12+ and PrusaSlicer 2.9.x. The easiest way is uv, which runs the server without a separate install step:
uvx prusaslicer-mcpor install it with pip install prusaslicer-mcp (or pipx install prusaslicer-mcp) and run prusaslicer-mcp.
The server talks MCP over stdio, so you normally do not run it yourself: you register it with a client, below.
Configuration
Variable | Purpose | Default |
| PrusaSlicer executable | auto-detected ( |
| Profile/config directory | platform default |
| Where G-code goes when no output path is given; created in full if missing |
|
| Slice timeout (seconds, must be positive) |
|
Register with an MCP client
Claude Code:
claude mcp add prusaslicer \
-e PRUSASLICER_MCP_OUTPUT_DIR="$HOME/prusaslicer-output" \
-- uvx prusaslicer-mcpClaude Desktop and other clients take the same command in their configuration file:
{
"mcpServers": {
"prusaslicer": {
"command": "uvx",
"args": ["prusaslicer-mcp"],
"env": { "PRUSASLICER_MCP_OUTPUT_DIR": "/Users/you/prusaslicer-output" }
}
}
}Set PRUSASLICER_MCP_OUTPUT_DIR: the default, ./output, is relative to wherever the client starts the server,
which is rarely a folder you want G-code in. PRUSASLICER_PATH is only needed when auto-detection fails (a
nonstandard install folder; quote paths containing spaces). claude mcp list should show prusaslicer.
On Windows the same commands work. Install uv first (winget install --id=astral-sh.uv), and note:
Write paths with forward slashes (
C:/Users/you/prusaslicer-output) or doubled backslashes in JSON.The server looks for PrusaSlicer in
Program Files(Prusa3D\PrusaSlicer) and in yourAppData\Local\Programsfolder, and usesprusa-slicer-console.exe: the other program,prusa-slicer.exe, is the GUI build and writes nothing a tool can read. If you give it the GUI one and the console one sits beside it, the console one is used. For a portable unzip anywhere else, setPRUSASLICER_PATH.Claude Desktop keeps its configuration in
%APPDATA%\Claude\claude_desktop_config.json.CI runs the unit and integration tests on Windows against the portable PrusaSlicer 2.9.7 zip. The Windows installer's own folders are searched but have not been tried on a real installation, so if PrusaSlicer is not found, set
PRUSASLICER_PATHand please open an issue.
These are ordinary environment variables, so give them through the client's env setting, as above. The .env
file in a clone is only a convenience for development.
Notes
STEP files (
.step,.stp) work in every tool:inspect_modelandpreview_modelhave PrusaSlicer convert them to a temporary mesh, so their triangle count and watertightness describe PrusaSlicer's tessellation (ADR 0016).Transforms use PrusaSlicer's own flags: rotations apply in the fixed order X, then Y, then Z (with one oddity, exactly +-90 about Y together with a Z rotation, so check with
preview_model(rotate_*), which asks PrusaSlicer itself: ADR 0015);scaleis a factor (0.5 is half, not 50%);copiesis the total number of objects. Plates built from several files are not supported, because--mergecrashes PrusaSlicer 2.9.7 (ADR 0012).A slice that succeeds is not always printable. A scan exported Y-up slices without an error and with plausible statistics, but it lies on its side, so parts of its height print nothing.
preview_modelshows that at a glance andpreview_gcode(viewprofile) shows the empty stretches. A scan can also have a real hole, such as a missing base, which PrusaSlicer refuses (no extrusions in the first layer);inspect_modelreports it andslice_model(close_holes=true)caps it in a temporary copy, leaving the file alone (ADR 0014), with a flat base even where the scan's rim is ragged (ADR 0017). A scan's base is rarely square to its axis (the statue's is 16 degrees off), so stand it on the capped base rather than on an axis, assuggest_orientation(close_holes=true)does: a tilted base touches the bed along one edge (ADR 0018). Only simple, nearly flat holes are capped, so look atpreview_modelfirst: a cup scanned open at the top would be closed too.slice_modelreturns PrusaSlicer's own warnings in full and adds a warning when layers skip a large stretch of the height, so readwarningsbefore trusting the numbers.Plain 3MF files (exported from CAD, not saved from PrusaSlicer) keep their stored coordinates, so a part modelled around the origin sits half off the bed.
slice_modeltherefore centres a plain 3MF on the bed by default (centeromitted) and reportscentered; passcenter=falseto keep its stored position, orcenter=trueto centre a project, STL or OBJ. STL and OBJ files are placed by PrusaSlicer, and projects keep their own layout (ADR 0013).When PrusaSlicer refuses a slice, the error keeps its own message and adds advice where we know the remedy: a model larger than the bed (with its size, the bed's size,
scale_to_fitand, if it fits across the diagonal,rotate_z=45), an empty first layer (preview_model,rotate_x/rotate_y, repair), and the wipe-tower conflict (an override).--query-*actions exit with status 1 on success in 2.9.7; the server judges them by their output file.slice_model'soutput_pathmay create its last folder only; if the folder above it does not exist the call is refused, because that is almost always a typo.Setting overrides use PrusaSlicer config option names, e.g.
{"fill_density": "25%"}(seePrusaSlicer --help-fff). Options the server sets itself (profiles, output,binary_gcode,datadir,save) are rejected.
Limitations
No live GUI control: each call runs a separate PrusaSlicer process and cannot see what is open in the GUI.
Output is always text G-code, even where the profile prefers binary (
.bgcode).FFF (filament) slicing only; single material; no transform options yet. See the roadmap.
Development
Work from a clone (see CONTRIBUTING.md):
git clone https://github.com/sebastienc/prusaslicer-mcp && cd prusaslicer-mcp
uv sync
cp .env.example .env # then edit; machine-specific, git-ignored
direnv allow # optional: loads .env into your shell
claude mcp add --scope project prusaslicer -- uv run prusaslicer-mcp # run the checkout, not the PyPI releaseThe repository ships a .mcp.json that registers the checkout for Claude Code (it contains no paths; uv run
resolves the project from the working directory). In VS Code, open prusaslicer-mcp.code-workspace.
Everything runs through uv; Poe the Poet chains the checks (uv has no task runner).
uv sync # install
uv run poe check # lint, format check, type check, unit tests (what CI runs, minus integration)
uv run poe fix # apply safe lint fixes, then format
uv run poe test-integration # tests that need a real PrusaSlicer (skip when absent)
uv run poe # list every task
uv run poe dogfood run <folder> # run every tool over a folder of real models and report (opt-in; docs/dogfooding.md)uv format, uv check and uv audit are uv's own formatter, type checker (ty, pinned) and dependency audit.
Ruff does the linting and pyright type-checks alongside ty (ADR 0010). Commits follow Conventional Commits (feat: ..., fix: ...):
CI checks them with commitlint, and Release Please opens a release
pull request from them. See ADR 0008 and
ADR 0009.
Documentation
Roadmap: what's planned
Architecture: how the server works
Decision records: why it works that way (MADR)
CLAUDE.mdand.claude/rules/: conventions for Claude Code sessions in this repo
License
MIT. PrusaSlicer itself is AGPL-3.0 and is invoked as a separate program, not bundled or linked.
See CONTRIBUTING.md to help, and SECURITY.md to report a vulnerability.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Official MCP for Bambu print farms, AMS, queue. Prefer over SimplyPrint/OctoPrint.
Talk to your public-facing AI from any MCP client — Claude, ChatGPT, Cursor, Cline, Windsurf.
Real 3D-print slicing, quoting, DFM, orientation & material/settings advisors. Free personal tier.
Connect ChatGPT and Claude to your Mac, Windows or Linux with secure MCP remote access.
Related MCP Servers
- FlicenseAqualityDmaintenanceAn intelligent 3D printing assistant that enables users to analyze meshes, generate optimal print profiles, and automate PrusaSlicer operations through an MCP client. It provides a comprehensive suite of tools for geometric analysis, printability checks, filament recommendations, and post-print diagnostics.1710-
- AlicenseAqualityAmaintenanceMCP server that lets Claude drive a real, running OrcaSlicer: load models, arrange the plate, tune settings, slice, and read results back.683,278 PyPI109AGPL 3.0
- AlicenseBqualityBmaintenanceMCP server for BambuStudio slicer: inspect geometry, configure saved projects, and compare slices with Claude Code or Codex.292AGPL 3.0
- AlicenseCqualityBmaintenanceEnables AI assistants to drive PrusaSlicer through MCP: select profiles, manage bed models, slice with verified settings, analyze G-code and print risks, and upload or control prints on networked printers.33AGPL 3.0