cups-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.
cups-mcp
An MCP server that lets an AI assistant (any MCP client) print on your network through CUPS.
Why this one?
Most printer MCP servers print a file path on the server, which only works when the AI runs on the same machine. This one also works for assistants that run elsewhere, such as web or mobile clients:
Secure file transfer. The client gets a one-time upload link, valid for 15 minutes, uploads the file straight to your private S3-compatible bucket, and prints it by id. Files never pass through the conversation, the server never reads arbitrary paths on your machine, and uploads are deleted after printing.
Real printer options. Files go to CUPS unchanged (PDF, PostScript, PNG, JPEG, TIFF, plain text). Every print tool takes scaling, resolution, duplex, page ranges, paper and quality, plus any option the printer itself offers (tray, media type, pages per sheet, ...), checked against what that printer supports.
Formatted documents (HTML, Markdown, Word) aren't converted: the client makes a PDF and prints that.
Related MCP server: printagent
Tools
Tool | What it does |
| Printer status and jobs |
| What a printer accepts, with allowed values |
| Print plain text |
| Upload a file, then print it by id |
| Print a small file sent inline (tiny files only) |
Every print tool takes the same options: copies, duplex, page_ranges, paper, quality,
scaling (auto, fit, fill, none), ppi, and options for anything else the printer accepts.
Install
Needs Linux with CUPS, Python 3.11+, and the libcups development headers (or your distro's
python-pycups package).
python -m venv venv && venv/bin/pip install .
venv/bin/cups-mcp # stdio, for local clients
venv/bin/cups-mcp --http # HTTP on 127.0.0.1:8710/mcpFor a local client that starts servers itself:
{
"mcpServers": {
"printer": {
"command": "/path/to/venv/bin/cups-mcp",
"env": { "MCP_PRINTER": "Office_Printer" }
}
}
}To run it permanently over HTTP, see examples/cups-mcp.service and "Connecting remote clients" below.
Settings (environment variables)
Variable | Default | |
|
| HTTP listener (always 127.0.0.1) |
| – | Public hostname(s) in front of it, comma-separated |
| – | Extra browser origins allowed to call it, comma-separated, e.g. |
| CUPS default, else first printer | |
| local CUPS | A CUPS server on another machine, e.g. |
| – | Password for a CUPS server that asks for one (with |
|
| Largest file accepted for printing, in MiB |
|
| Most copies allowed in one print job |
| – , | Upload storage; see |
To print through CUPS on another machine, that server must accept remote clients (cupsctl --remote-any,
or Listen/Allow in cupsd.conf). If it requires a login, set CUPS_USER and MCP_CUPS_PASSWORD
(preferably with CUPS_ENCRYPTION=Required).
Connecting remote clients
Remote (web) clients need a public HTTPS URL. The server has no authentication of its own: put it
behind a reverse proxy or tunnel that does (for example an OAuth-capable proxy or a zero-trust tunnel), and
set MCP_PUBLIC_HOST to that hostname. If the client calls it from a browser page, add that page's origin
to MCP_ALLOWED_ORIGINS. For uploads, the client must be able to reach your bucket's endpoint.
Security
Run it as a dedicated user;
examples/cups-mcp.serviceshows a sandboxed systemd unit.Use a storage key limited to the one bucket, and a lifecycle rule that deletes old objects.
The client can upload but never gets a link to read an upload back, and the server never downloads from URLs it's given.
Known issues
Blank pages from some PDFs. libcupsfilters 2.2.x with PDFio 1.6.6 or older prints PDFs with chained stream filters (e.g.
[/ASCII85Decode /FlateDecode], ReportLab's default) as blank pages, while reporting success. Fixed in PDFio 1.6.7 (libcupsfilters#301): update PDFio, or re-save such PDFs with Flate only (e.g.qpdf --decode-level=generalized).Linux only.
Licence
MIT, see LICENSE.
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
Print from Claude and ChatGPT to your own printer. Free for 5 prints a month; Plus $7.99/mo.
HTML/URL to PDF rendering API with a remote MCP server. Send HTML or a URL, get a print-ready PDF back.
MCP server for the PDFGate API. Generate PDFs, manage documents and handle e-signatures.
Screenshots, PDFs, image editing, QR codes, email validation and more through one hosted MCP server.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables MCP clients to submit, slice, and start 3D prints with configurable gates, preview approval, and monitoring, via a self-hosted print daemon.MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to submit PDFs or JSON-rendered templates to local printers, check printer status, and manage print jobs through MCP tools.18 npmMIT
- AlicenseNot gradedqualityCmaintenanceEnables MCP clients such as Claude to list installed Windows printers and print PDF files with options for copies, page ranges, monochrome, and duplex.54 npmMIT
- AlicenseBqualityBmaintenanceEnables users to upload documents over HTTP and send them to IPP/IPPS printers or CUPS through MCP tools for validation, printing, job monitoring, and cancellation.13MIT