{"slug": "pasting-screenshots-into-claude-code-over-ssh", "title": "Pasting screenshots into Claude Code over SSH", "summary": "A developer documented a workaround for pasting screenshots into Claude Code over SSH by combining the clipssh CLI tool, a macOS Shortcuts automation, and SSH connection multiplexing. The setup uses clipssh's Bash script to copy an image to a temporary file on the remote host at CLIPSSH_REMOTE_DIR=/tmp/claude-image-clipboard, and adds ControlMaster auto with ControlPersist 4h in ~/.ssh/config to stop 1Password from prompting for SSH approval on each invocation.", "body_md": "I should soon be done with kicking Claude out of my personal MacBook to a local box. One of the first things I missed is the ability to paste screenshots with ``` `⌃`` V` ```: the remote terminal doesn’t know about my clipboard.\n\nI wanted my solution to look like this:\n\nFor the transport part, turns out Samuel Lawrentz had a similar need and published a CLI tool called [clipssh](https://github.com/samuellawrentz/clipssh): basically a Bash script that writes the image to a temporary file and copies it to the remote host. I didn’t want to install this with a package manager, so I just stuck the [main script](https://github.com/samuellawrentz/clipssh/blob/main/clipssh) in `.local/bin`.\n\nThe second part is a shortcut in the Shortcuts app that comes into play after I’d already captured the screenshot: Shottr is now the frontmost app and pressing # expand the path so pngpaste (a dependency of clipssh) is there\nexport PATH=\"/opt/homebrew/bin:$HOME/.local/bin:$PATH\"\nexport CLIPSSH_HOST=\"username@100.113.x.x\"\nexport CLIPSSH_REMOTE_DIR=\"/tmp/claude-image-clipboard\"\nsleep 0.3\n# dismiss Shottr (auto copies the screenshot to my local clipboard)\nosascript -e 'tell application \"System Events\" to key code 53' \nsleep 0.3\nclipssh\n```\n\nOne thing left. 1Password kept prompting me to approve the SSH connection each time I invoked this, so I made the connection persist for 4 hours in `~/.ssh/config`:\n\n```\nHost 100.113.x.x\n  ControlMaster auto\n  ControlPath ~/.ssh/cm-%C\n  ControlPersist 4h\n```\n\n", "url": "https://wpnews.pro/news/pasting-screenshots-into-claude-code-over-ssh", "canonical_source": "https://thebiglog.com/posts/send-agent-harness-screenshots-via-ssh", "published_at": "2026-09-29 21:00:00+00:00", "updated_at": "2026-09-29 22:17:39.683811+00:00", "lang": "en", "topics": ["ai-tools", "developer-tools", "ai-agents"], "entities": ["Claude Code", "clipssh", "Samuel Lawrentz", "Shottr", "pngpaste", "1Password", "macOS Shortcuts"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/pasting-screenshots-into-claude-code-over-ssh", "markdown": "https://wpnews.pro/news/pasting-screenshots-into-claude-code-over-ssh.md", "text": "https://wpnews.pro/news/pasting-screenshots-into-claude-code-over-ssh.txt", "jsonld": "https://wpnews.pro/news/pasting-screenshots-into-claude-code-over-ssh.jsonld"}}