A VS Code extension that adds image support to Claude Code, enabling you to paste, drag-drop, and attach images directly in your Claude conversations.
- 📎 File Attachment: Click the attachment button to select images
- 🖱️ Drag & Drop: Drag images directly into the chat input
- ⌨️ Clipboard Paste: Paste images using OS-native shortcuts (Cmd+V on Mac, Ctrl+V on Windows)
- PNG, JPG, JPEG, GIF, WebP, BMP
- Configurable file size limits (default: 10MB)
- Image preview before sending
- Mac: Cmd+V for paste, Cmd+Shift+C to open chat
- Windows/Linux: Ctrl+V for paste, Ctrl+Shift+C to open chat
- Dynamic UI that shows correct shortcuts for your OS
- Seamless integration with Claude Code CLI
- Saves images to temp files and passes them to Claude Code
- Automatic cleanup of temporary files
code --install-extension claude-code-image-support-1.0.0.vsix- Clone this repository
- Open in VS Code
- Press
F5to run in Extension Development Host
- Open Claude Chat: Press
Cmd+Shift+C(Mac) orCtrl+Shift+C(Windows/Linux) - Add Images:
- Click the 📎 button to select files
- Drag & drop images into the text area
- Copy/paste images from clipboard or browser
- Send Message: Type your message and click Send or press
Cmd/Ctrl+Enter
Access settings via VS Code Preferences:
claude-code-image-support.imageSupport.enabled: Enable/disable image supportclaude-code-image-support.imageSupport.maxSize: Maximum image size in MB (default: 10)claude-code-image-support.imageSupport.supportedFormats: Supported image formatsclaude-code-image-support.imageSupport.showPreview: Show image preview before sending
- VS Code 1.74.0 or higher
- Claude Code CLI installed and accessible in PATH
- Node.js and npm (for development)
npm install
npm run compilenpm install -g vsce
npx vsce packagenpm testThe extension automatically detects your operating system and adjusts:
- Keyboard shortcuts in UI hints
- Paste event handling
- File path management
- Capture: Detects images from paste, drag-drop, or file selection
- Validate: Checks format and size against configuration
- Process: Converts to base64 and saves to temporary files
- Transmit: Passes image paths to Claude Code CLI
- Cleanup: Automatically removes temporary files
- Comprehensive error messages for unsupported formats
- Size limit warnings with current file size
- Fallback instructions if CLI communication fails
- Debug logging for troubleshooting
- Open VS Code Developer Tools (
Help→Toggle Developer Tools) - Go to Console tab
- Try pasting an image and check for debug output
- Image not pasting: Check browser permissions and image format
- Large file errors: Adjust
maxSizesetting or compress image - CLI errors: Ensure Claude Code is properly installed and in PATH
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
MIT License - see LICENSE file for details
- Built for Claude Code by Anthropic
- Inspired by the need for native image support in Claude Code VS Code integration
- Thanks to the VS Code extension API and community
Note: This extension is not officially affiliated with Anthropic. It's a community-built solution to add image support to Claude Code in VS Code.