Skip to content

Model Context Protocol (MCP) server for seamless ShareX integration with Claude Code - view screenshots and GIFs instantly

License

Notifications You must be signed in to change notification settings

BuildAppolis/sharex-mcp-server

Repository files navigation

ShareX MCP Server

npm version License: MIT

A Model Context Protocol (MCP) server that seamlessly integrates ShareX screenshots and GIFs with Claude Code, enabling AI-powered analysis of your visual content.

Built by BuildAppolis - Building the future, one app at a time.

Features

πŸ“Έ Screenshot Management

  • Instant Access: View your latest screenshots directly in Claude Code
  • Multi-Screenshot Support: Retrieve up to 5 recent screenshots at once
  • Smart Caching: Tracks your 10 most recent screenshots automatically
  • File Metadata: See file sizes, timestamps, and types at a glance

🎬 Advanced GIF Handling

  • Automatic Frame Extraction: GIFs are automatically broken down into individual frames
  • Indexed Selection: Access GIFs by number (1-5) for easy reference
  • Smart Frame Sampling: Intelligently selects frames from long GIFs
  • Large File Support: Handles GIFs up to 50MB with graceful degradation
  • Frame Caching: Extracted frames are cached for instant access

πŸ”„ Real-Time Monitoring

  • Live Updates: Automatically detects new screenshots as you take them
  • File Watching: Monitors your ShareX screenshot directory in real-time
  • Auto-Cleanup: Maintains optimal performance by managing cache limits

Quick Start

Prerequisites

  • Windows 10/11 (with optional WSL support)
  • ShareX installed on Windows
  • Claude Code installed
  • Node.js 18+ (for installation)

Installation

Option 1: Install from NPM (Recommended)

# Install globally
npm install -g @buildappolis/sharex-mcp-server

# Register with Claude Code
claude mcp add sharex -- npx -y @buildappolis/sharex-mcp-server

Option 2: Quick Install Script

Windows (PowerShell) - Also configures WSL automatically

# One-line installer that handles both Windows and WSL
iwr -useb https://raw.githubusercontent.com/buildappolis/sharex-mcp-server/main/setup.ps1 | iex

The installer will:

  1. Install the MCP server on Windows
  2. Register it with Claude Code on Windows
  3. Automatically detect and configure any WSL distributions
  4. Set up everything for immediate use

For WSL Users: The Windows installer automatically configures WSL to connect to the Windows-installed server. If you need to manually configure WSL after installation:

# In WSL, register the Windows server
claude mcp add sharex --scope user -- node /mnt/c/Users/YOUR_USERNAME/sharex-mcp-server/dist/index.js

Verify Installation

# Check if the server is registered
claude mcp list

# You should see:
# sharex: βœ“ Connected

Usage

Basic Commands

Once installed, just ask Claude:

  • "Look at my latest screenshot" - Shows your most recent screenshot
  • "Check my latest GIF" - Automatically extracts and displays frames from your latest GIF
  • "Show me the last 3 screenshots" - Displays multiple recent screenshots
  • "List my GIFs" - Shows numbered list of available GIFs
  • "Show GIF number 2" - Displays the second most recent GIF

Taking Screenshots with ShareX

  1. Press your ShareX hotkey (default: PrtScn)
  2. Capture your screen area
  3. Ask Claude to view it immediately - no file navigation needed!

Recording GIFs with ShareX

  1. Press your ShareX GIF hotkey (default: Shift+PrtScn)
  2. Record your screen
  3. Stop recording
  4. Ask Claude to view the GIF - frames are extracted automatically!

Features in Action

Smart GIF Processing

When you ask to see a GIF, the server:

  • Detects the GIF format automatically
  • Extracts up to 10 representative frames
  • Shows frame numbers and metadata
  • Caches the extraction for instant replay

Indexed Access

User: "List my GIFs"
Claude: Available GIFs:
1. screen_recording.gif - 2.3 MB - 2 mins ago
2. demo_animation.gif - 1.1 MB - 10 mins ago
3. bug_report.gif - 4.5 MB - 1 hour ago

User: "Show number 3"
Claude: [Displays frames from bug_report.gif]

Configuration

The MCP server uses ShareX's default screenshot location automatically. If you've customized your ShareX settings, the server will detect and use your custom path.

Default Limits

  • Screenshots: Tracks 10 most recent
  • GIFs: Tracks 5 most recent
  • Frames per GIF: Extracts up to 10 frames
  • Max GIF size: 50MB

Troubleshooting

Server Not Connected

If using NPM package:

# Re-register the server
claude mcp remove sharex
claude mcp add sharex -- npx -y @buildappolis/sharex-mcp-server

If using local installation:

# Re-register the server
claude mcp remove sharex
claude mcp add sharex --scope user -- cmd /c node "C:\Users\%USERNAME%\sharex-mcp-server\dist\index.js"

Can't See Screenshots

  1. Ensure ShareX is saving to Documents\ShareX\Screenshots
  2. Take a new screenshot to trigger detection
  3. Check server status: claude mcp list

GIF Issues

  • GIFs over 50MB will show metadata only
  • Corrupted GIFs will display an error message
  • Try recording a shorter GIF if extraction fails

Uninstall

NPM Package

# Remove from Claude Code
claude mcp remove sharex

# Uninstall package
npm uninstall -g @buildappolis/sharex-mcp-server

Local Installation

Windows

claude mcp remove sharex
Remove-Item -Recurse -Force "$env:USERPROFILE\sharex-mcp-server"

WSL

claude mcp remove sharex
rm -rf ~/sharex-mcp-server

Contributing

Want to help improve ShareX MCP Server? Check out our Contributing Guide for development setup and guidelines.

Support

License

MIT License - See LICENSE file for details.


ShareX MCP Server is a BuildAppolis project, crafted with care to enhance your AI-assisted workflow.

About

Model Context Protocol (MCP) server for seamless ShareX integration with Claude Code - view screenshots and GIFs instantly

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published