使用说明
mcp-screenshots
A cross-platform MCP (Model Context Protocol) server for capturing screenshots from applications.
Features
- Cross-platform support: Works on Windows (full support) and macOS (full screen only)
- Multiple capture modes:
- Full screen capture (single or all monitors)
- Interactive region selection (Windows only)
- Multi-monitor support: Enumerate and capture from specific displays
- Flexible output: PNG or JPEG format with configurable quality and scale
- Screenshot management: List and manage captured screenshots
Tools
listScreens
Lists all available screens/monitors on the system.
takeScreenshot
Captures a full-screen screenshot.
Parameters:
screenId(optional): Screen ID to capture (0-based index)allScreens(optional): Capture all screens combinedincludeImage(optional, default: true): Include base64 image in responsescale(optional, default: 0.75): Scale factor (0.1-1.0)format(optional, default: "png"): Output format ("png" or "jpeg")
takeRegionScreenshot (Windows only)
Captures an interactive region selection screenshot.
Parameters:
prompt(optional): Hint text shown during selectionincludeImage(optional, default: true): Include base64 image in responsescale(optional, default: 1.0): Scale factor (0.1-1.0)format(optional, default: "png"): Output formattimeoutMs(optional, default: 120000): Timeout in milliseconds
listScreenshots
Lists previously captured screenshots.
Parameters:
limit(optional, default: 50): Maximum number of screenshots to return
Installation
npm install
npm run build
Windows Requirements
The Windows implementation uses a C# helper application. To build it:
cd helpers/windows/RegionSnip
dotnet build -c Release
Then copy the output to the bin/ directory:
cp bin/Release/net8.0-windows/RegionSnip.exe ../../../bin/
macOS Requirements
- Screen Recording permission must be granted in System Preferences > Security & Privacy > Privacy > Screen Recording
Usage
With Claude Desktop
Add to your Claude Desktop config (claude_desktop_config.json):
{
"mcpServers": {
"screenshots": {
"command": "node",
"args": ["/path/to/mcp-screenshots/dist/index.js"]
}
}
}
With Cursor/Windsurf
Add to your MCP config:
{
"mcpServers": {
"screenshots": {
"command": "node",
"args": ["/path/to/mcp-screenshots/dist/index.js"]
}
}
}
Testing with MCP Inspector
npx @modelcontextprotocol/inspector node dist/index.js
Platform Support
| Feature | Windows | macOS |
|---|---|---|
| Full screen capture | Yes | Yes |
| Multi-monitor | Yes | Yes |
| Region selection | Yes | No |
| Screen enumeration | Yes | Yes |
Credits
This project was built with inspiration and code from:
- mcp-windows-screenshot - Windows screenshot capture via C# helper with GDI+ and interactive region selection
- webdev-mcp - Cross-platform screenshot patterns using native OS commands
License
MIT