You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Support pasting images from iOS → macOS (Universal Clipboard) into Codex CLI composer #4366
Summary
Pasting screenshots/images copied on my iPhone (Share → Copy) into the Codex CLI interactive composer doesn’t work. The same workflow works in other tools (e.g., Claude Code, Slack, Notes). Request: let Codex accept Universal Clipboard image pastes (PNG/JPEG/HEIC), auto-convert if needed, and attach them to the current message.
Why this matters
For quick bug reports / UI reviews I often copy a screenshot on iPhone and paste straight into my Mac. Having to save/airdrop/upload adds friction. Direct paste would make Codex a drop-in replacement for my other dev tools.
Steps to reproduce
1. On iPhone: take a screenshot → Share → Copy.
2. On Mac: focus the Codex CLI composer (codex with no args).
3. Press ⌘V (or Ctrl+V, depending on key handling).
4. Nothing attaches.
Expected
• Codex detects an image on the system clipboard (from Universal Clipboard).
• Shows the thumbnail preview like when pasting a local clipboard screenshot.
• Attaches it to the current prompt.
Actual
• Paste is ignored (no attachment, no error).
Current workaround
• Use pngpaste /tmp/shot.png && codex -i /tmp/shot.png ... (or drag-and-drop). Works but breaks the fast “copy on phone → paste on Mac” loop.
Proposed implementation notes
• On macOS, check NSPasteboard.general for these types:
• public.png, public.jpeg, public.tiff, public.heic, and file promises (NSPasteboardTypeFileURL, public.file-url).
• Universal Clipboard can provide a promised item (lazy transfer). Request data for any supported image UTI and, if HEIC, transcode to PNG (ImageIO) into a temp file before attaching.
• Hard-limit image size (e.g., 10–20 MB) and strip EXIF for privacy.
• Show a small toast/error if paste contains an unsupported type.
Acceptance criteria
• Pasting an iPhone screenshot (Share → Copy) into Codex CLI on macOS attaches the image.
• Works for PNG/JPEG/HEIC; HEIC auto-converts to PNG.
• No regression for existing local clipboard screenshot pastes.
• Clear error when paste exceeds size limits.
Activity
etraut-openai commentedon Nov 28, 2025
We are tracking this in #3939, so I'm going to close this issue.