cc-clip CLI

Clipboard bridge over SSH: images from your local clipboard reach Claude Code, Codex CLI and Cursor running on a remote server

  • 180 ★ on the repository
  • Last commit
CLI

Extended access

Why this level

  • Installs a shim in place of xclip and wl-paste on the server and writes notification hooks into agent configs such as ~/.cursor/hooks.json
  • Runs a local daemon with access to your clipboard and adds a RemoteForward to the SSH config
  • Loopback on the server is shared by all its users: the token does not defend against another process of the same user
All reasons and checks

shunmeicho/cc-clip

Install

Manual install

curl -fsSL https://raw.githubusercontent.com/ShunmeiCho/cc-clip/main/scripts/install.sh | sh

The installer from the README. Read the script before running it. Then `cc-clip setup myserver` sets up the host.

Access and checks

How we review

Extended accessThe tool runs code or makes network calls and only reads external data.

  • Installs a shim in place of xclip and wl-paste on the server and writes notification hooks into agent configs such as ~/.cursor/hooks.json
  • Runs a local daemon with access to your clipboard and adds a RemoteForward to the SSH config
  • Loopback on the server is shared by all its users: the token does not defend against another process of the same user

This is third-party code. Review the repository files before installing.

What it does

cc-clip carries your machine's clipboard into a remote SSH session. After setup, Ctrl+V in Claude Code, opencode, Cursor or Kimi Code on the server pastes an image copied on your Mac, while Codex CLI and Grok Build receive it through a virtual Xvfb display. Without the bridge you would save the screenshot, send it with scp and type the file path. A local daemon listens on loopback only, SSH forwards its port to the server with RemoteForward, and a shim stands in for xclip or wl-paste on the server. A token with a 30-day lifetime guards access. The reverse direction works too: `git diff | cc-clip copy` puts text on the local clipboard without the line breaks a terminal adds. When the remote agent finishes a turn or waits for a tool approval, a notification appears on your desktop. `cc-clip doctor --host myserver` tests every link in the chain and prints [pass] or [FAIL] with the reason.

Who it is for. Developers who run Claude Code or Codex CLI on a remote Linux server from a Mac and are tired of sending screenshots by hand.

Good fit when

  • You need the agent on a server to see a UI error screenshot copied on your Mac
  • Your code lives on a cloud machine or work server where Claude Code runs over SSH
  • Long terminal lines reach the local clipboard with stray line breaks and you need exact text
  • You switch between windows and want a signal when the agent waits for a command approval
  • Image paste stopped working and you want to diagnose the whole chain with one command

Not a fit when

  • The agent runs on your local machine, so a remote bridge adds nothing
  • The server has no SSH key access and no named Host entry in `~/.ssh/config`
  • A Windows workstation where you expect stability: support there is experimental
  • Security policy forbids shims and hooks in the home directory on a shared server

Example request

I copied a screenshot on my Mac. Paste it into the request on the remote server and explain why the button on it is misaligned.

Limitations

  • The stable path is macOS 13 or newer locally and Linux (amd64 or arm64) on the server with curl, bash and xclip or wl-paste. The README calls Windows experimental.
  • Codex CLI needs Xvfb. Without passwordless sudo, cc-clip prints the install command and you run it by hand.
  • After `cc-clip setup`, open a new SSH session: an old one does not hold the reverse tunnel. Cursor needs DISPLAY or WAYLAND_DISPLAY set on the server.
  • The opencode and Antigravity integrations are covered by generation tests but have not been run end to end.

How to disable. Run `cc-clip uninstall` on the server and `cc-clip uninstall --host myserver` locally. Add `--codex` for Codex. The local daemon is removed with `cc-clip service uninstall`.

FAQ

How do I paste an image into Claude Code over SSH?

Run `cc-clip setup myserver`, open a new SSH session and press Ctrl+V in Claude Code on the server. The agent attaches the image from your local clipboard and your Mac shows a notification with its size and format.

Why does Codex CLI need a separate flag?

Codex reads the X11 clipboard directly and never calls xclip, so the usual shim cannot reach it. The `--codex` flag adds Xvfb and the `cc-clip x11-bridge` bridge on the server.

Is the daemon port open to other people?

No, the daemon and the forwarded port bind to loopback only and there is no public listener. Other users on the same server share that loopback, so the token lives in a file with mode 0600.

What if paste does not work?

Copy an image locally and run `cc-clip doctor --host myserver`: it checks the daemon, forward, token and shim. Fix the first [FAIL] line, the later ones usually follow from it.

Does cc-clip work on Windows?

Windows support is experimental: the main README path covers macOS, and Windows has its own quick start with the `send` and `hotkey` commands.

Discussion

No questions or reviews yet.

CLI tools

A native macOS terminal built on Ghostty with vertical tabs and notifications when an agent needs your input

CLIBroad access28.7KRepository stars

clawk is a virtual-environment CLI that snapshots a Linux machine’s memory and disk so running processes can be resumed later.

CLIBroad access1KRepository stars
Official

The MCP server of the purple SSH manager: an agent reads hosts from ~/.ssh/config and their containers, commands and container control are opt-in

MCP serverBroad access769Repository stars

MCP SSH Manager

mcp-ssh-manager

Managing several SSH connections from Claude Code and Codex: commands, file transfer, databases and backups

MCP serverBroad access532Repository stars

An SSH skill for Codex and Claude Code: remote commands, file transfer and tunnels with one JSON result and replay protection.

SkillBroad access553Repository stars

Token and cost reports across Claude Code, Gemini CLI, Codex and Cursor in one view, built from local logs with no keys.

CLIExtended access117Repository stars

README in short

The README opens with a three-step quick start: install, set up a host, open a new SSH session. It continues with a table of targets per agent, feature walkthroughs with what, why, how and what you will see, a command reference, an architecture sketch, the security model and troubleshooting.

README badge

Report a problem

Foxx AIcc-clip
Foxx AI

I am Foxx AI and I have already vetted this tool. Ask about install, setup or anything else, and I will keep it simple.