Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Codex Image PasteNew to Visual Studio Code? Get it now.
Codex Image Paste

Codex Image Paste

JamesWang

|
2 installs
| (0) | Free
Paste Mac clipboard images into Codex in a VS Code Remote-SSH terminal with one shortcut.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Codex Image Paste

Paste a Mac clipboard image into Codex running in a VS Code Remote-SSH terminal. Press Control–Option–V to copy the image into the remote terminal's directory and insert its path into the terminal. No X11 forwarding or remote clipboard service is needed.

**中文速用:**在 Mac 的 VS Code 中通过 Remote-SSH 打开远端项目,在集成终端运行 Codex。复制截图后按 Control–Option–V,扩展会把图片传到远端并把路径填入终端;补上你的问题后按回车。

Requirements

  • VS Code 1.74 or newer on macOS
  • VS Code Remote-SSH connected to a Linux host
  • A VS Code integrated terminal running Codex on the remote host
  • VS Code terminal shell integration enabled, or an open remote workspace folder as a fallback

Use

  1. Copy an image or take a screenshot to the Mac clipboard.
  2. Focus the Codex terminal in VS Code.
  3. Press Control–Option–V (Ctrl+Alt+V in VS Code keybinding syntax).
  4. Add your question and press Enter.

The extension saves a PNG in <terminal directory>/.codex-paste/ and inserts Please inspect this image: <remote path> without pressing Enter. If VS Code cannot detect the terminal directory, it uses the open remote workspace folder. The file path is sent as text in the prompt; this is not a native image attachment.

If your screenshot tool saves a file instead of copying image data, use its Copy to Clipboard option first.

Settings

Setting Default Purpose
codexImagePaste.directory .codex-paste Relative image directory under the terminal directory, or workspace fallback
codexImagePaste.terminalText Please inspect this image: {path} Text inserted into Codex; must contain {path}

The extension creates .codex-paste/.gitignore so screenshots are not accidentally committed. It does not delete pasted images automatically; remove the directory whenever you no longer need the images.

Troubleshooting

  • “Could not detect the remote terminal directory”: enable VS Code terminal shell integration or open the remote project folder in VS Code.
  • “No image found on the Mac clipboard”: copy the image pixels or a screenshot, then retry.
  • “requires VS Code on a Mac connected with Remote-SSH”: this extension reads the Mac clipboard from the local VS Code window. It does not work in a standalone SSH terminal.
  • No path appears: focus the integrated terminal before pressing Control–Option–V. You can also run Codex: Paste Clipboard Image to Remote Terminal from the Command Palette.

How it works

The local VS Code extension host reads the macOS clipboard with AppleScript. It converts TIFF or JPEG clipboard data to PNG using the built-in sips utility, then writes the PNG through VS Code's Remote-SSH file provider. The image stays on your remote host. The extension makes no network requests of its own.

Development

npm install
npm test
npm run package

The automated tests run on any platform. Clipboard and Remote-SSH behavior require a manual test on a Mac connected to Linux.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft