YetAnotherFileLayer

How to Get a Screenshot into Claude Code on a Remote Server

You take a screenshot of the broken UI on your Mac. But Claude Code is running on your VPS, inside an SSH session. Ctrl+V does nothing – the image sits in your local clipboard, and the agent can only read files that exist on its machine.

Here is the local answer first, then the one nobody covers: the remote case.

Pasting images into Claude Code locally

When Claude Code runs on the same machine as your clipboard, pasting works. Copy the image and paste it into the prompt – on most terminals that is Ctrl+V, on some setups (notably certain macOS terminals) the binding is Alt+V or Cmd+V depending on the terminal emulator. If pasting is flaky in your setup, there is a simpler path: save the screenshot and give Claude Code the file path. It reads images from disk without any clipboard involved:

> Look at ~/Desktop/bug.png – why is the button misaligned?

Why paste fails over SSH

The clipboard is machine-local. An SSH session carries keystrokes and text, not files – so no key binding will ever move a PNG from your Mac's clipboard onto the VPS's disk. Claude Code on the server can only read what is on the server. Every clipboard trick stops at the machine boundary.

  1. On your Mac: drag the screenshot onto yafl.dev – or from a terminal, yafl put ~/Desktop/bug.png. Sending needs a free account (uploads are tied to a revocable key – that's the trust model); the file is encrypted in your browser or CLI before a single byte leaves the machine. Downloading needs nothing.
  2. Copy the link. The decryption key rides in the #fragment of the URL and is never sent to any server.
  3. In your SSH session, tell the agent:
> Download https://yafl.dev/t/{id}#{key} and look at it – why is the button misaligned?

With the YAFL MCP server installed, Claude Code calls download_file, the image lands decrypted on the VPS disk, and the agent reads it like any local file. The link self-destructs after 24 hours – or upload it as a one-time link and it burns after the first download.

From an iPhone

Same move, no computer needed: screenshot → share sheet → open yafl.dev in Safari (signed in) → upload → copy the link → paste it into your Termius session. The agent on the VPS does the rest.

FAQ

Can Claude Code accept images? Yes. Locally it accepts pasted images and reads image files from a path. When Claude Code runs on a remote server, it can only read images that exist on that server's disk – transfer the file there first, for example with one YAFL link.

How do I paste a screenshot into the Claude Code terminal over SSH? You can't – the clipboard doesn't cross an SSH session. Upload the screenshot to yafl.dev (encrypted client-side), paste the link into the session, and let the agent download it with the YAFL MCP tool or yafl get.

How do I show Claude Code on a VPS something on my screen? Screenshot it, drag it onto yafl.dev, and hand the agent the link. One upload, one download_file call, and the agent sees exactly what you see.

Install: npx -y @yafldev/mcp with YAFL_API_KEY set, or the one-liner curl -fsSL https://yafl.dev/install.sh | sh.

Get started Full setup docs →