Skip to content

Feature request: SSH image paste support #10516

@mvanhorn

Description

@mvanhorn

Problem

When using Ghostty over SSH, there's no way to paste images from the local clipboard to remote tools that need file paths (like Claude Code, vim with image plugins, etc.).

Currently you have to:

  1. Save image locally
  2. scp it to the remote host
  3. Type or paste the remote path

This breaks the flow, especially when iterating quickly with AI coding assistants.

Proposed Solution

When pasting (Ctrl+V) with an image in the clipboard while in an SSH session:

  1. Detect image data in clipboard
  2. Find active SSH ControlMaster socket
  3. Auto-upload via SCP to /tmp/ghostty-paste-{uuid}.png
  4. Insert the remote file path as text

This uses existing ControlMaster sockets so there's no password prompt.

Use Case

I frequently use Claude Code over SSH and need to share screenshots/diagrams. This would make image sharing seamless.

Implementation

I have a working implementation ready if this is accepted: #10515

Config options:

  • ssh-image-paste = true/false (default: true)
  • ssh-image-paste-path = /tmp (configurable)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions