Copy Pasting image in Kiro Cli
Feature Description
When using the Kiro-CLI, i'm unable to copy paste directly an image (as in Claude Code). However, giving the path to the image works.
Use Case
- Giving a Screenshot to the cli to check directly
Additional Context
No response
I can paste an image from my clipboard on Mac using Ctrl+V in the CLI (same as in Claude Code). Yet, it ignores all the additional text prompt that I provide with the image and only analyzes the image...
i am on windows ,also not work
This still not works in WSL2 with kiro-cli. Dev/Support Feedback?
+1 , same issue, $XDG_RUNTIME_DIR/kiro-log/kiro-chat.log does not give information about the issue, and Kiro just complains with ● No image in clipboard
Still not working. As a workaround i made me a skill file, so that kiro will find last screenshots in the windows folder (/mnt/c/Users/....../Bilder/Screenshots/) WSL2 user here.
This is working now. Please confirm
Root cause for the WSL2 case (several people above, incl. leneffets, KrappRamiro, and my own report): this isn't a general "image paste is missing" gap, it's a specific fallback bug in the clipboard library.
Environment: kiro-cli 2.12.3, Ubuntu 24.04 on WSL2 (WSLg), WAYLAND_DISPLAY + DISPLAY both set.
What's happening: Kiro reads the clipboard via arboard (3.6.1 in this build). With WAYLAND_DISPLAY set, arboard tries its Wayland backend (wl-clipboard-rs 0.9.3) first, and silently falls back to X11 on failure (only logged at trace). wl-clipboard-rs requires the wlr-data-control/ext-data-control Wayland protocol, which WSLg's compositor does not implement. So arboard falls back to the XWayland clipboard - but WSLg only bridges text from the Windows clipboard to X11, not images. The image is really on the Wayland clipboard, but Kiro never looks there successfully, so it reports "No image in clipboard".
(Note: wl-paste/wl-copy from the reference wl-clipboard package do work on WSLg, because they fall back to the older core wl_data_device protocol when data-control is missing. wl-clipboard-rs has no such fallback - it's data-control-only.)
Evidence:
Image copied in Windows does reach the Wayland clipboard:
$ wl-paste --list-types
image/bmp
Minimal repro with the exact crate/version Kiro uses, with a valid image on the clipboard:
arboard::Clipboard::new()?.get_image()
→ ContentNotAvailable ("contents were not available in the requested format or the clipboard is empty")
Calling wl-clipboard-rs directly (what arboard's Wayland backend uses under the hood):
get_mime_types(...) → MissingProtocol { name: "ext-data-control, or wlr-data-control", version: 1 }
Confirmed independently - WSLg's compositor doesn't support the protocol at all:
$ wl-paste --watch true
Watch mode requires a compositor that supports the wlroots data-control protocol
The X11 read path itself works fine once an image is actually placed there (verified via arboard::set_image → separate process arboard::get_image round-trip) - the only gap is that nothing puts the image on the X11 clipboard on WSLg.
Suggested fix: add a core-protocol Wayland read path for images (or shell out to wl-paste, which already works on WSLg), since wl-clipboard-rs can't help here. Possibly relevant: kiro-cli appears to be built on the open-source aws/amazon-q-developer-cli, whose Cargo.lock pins the same arboard/wl-clipboard-rs combination - if the clipboard code is shared/inherited from there, the fix may need to land in both places.
Workaround in the meantime: mirror the copied image onto the X11 clipboard as image/png (e.g. xclip -selection clipboard -t image/png, or a small process that calls arboard::set_image and stays alive to serve the X11 selection). Once it's on X11, /paste finds it.
I made a small helper to make inline image paste work with Kiro-CLI in WSL, for images that are stored in the Windows clipboard: https://github.com/JonathanBerkeley/Image-Bridge
Not ideal, but handy for my purposes. Can paste inline many types of images in the Windows clipboard, from different sources (copied from file, copied from app, snipping tool, webp, etc).
@ElBlackwood Not my case, i dont use WSL nor WSL2, because i dont use Windows, im currently on Ubuntu Ubuntu 26.04 LTS , using Sway 1.12 (Wayland) .
I installed kiro-cli via nixpkgs
+1. BTW, Paste doesn't work also in Firefox on WSL
Workaround for image paste on WSL2/WSLg (kiro-cli 3.2.0, no sudo)
Kiro's /paste calls xclip from PATH. WSLg only provides screenshots as image/bmp on the Wayland clipboard, so
this copies them to the X11 clipboard as PNG.
# 1. tools, extracted into $HOME
mkdir -p /tmp/dl ~/.local/opt/kpaste && cd /tmp/dl
apt-get download wl-clipboard xclip libxmu6 libxt6t64 libice6 libsm6
for d in *.deb; do dpkg -x "$d" ~/.local/opt/kpaste; done
python3 -m venv ~/.local/opt/kpaste/venv && ~/.local/opt/kpaste/venv/bin/pip install pillow
# 2. xclip wrapper on PATH (Kiro looks for it there)
cat > ~/.local/bin/xclip <<'EOF'
#!/usr/bin/env bash
root="$HOME/.local/opt/kpaste"
export LD_LIBRARY_PATH="$root/usr/lib/x86_64-linux-gnu${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}"
exec "$root/usr/bin/xclip" "$@"
EOF
# 3. kpaste: Wayland BMP -> X11 PNG
cat > ~/.local/bin/kpaste <<'EOF'
#!/usr/bin/env bash
set -euo pipefail
root="$HOME/.local/opt/kpaste"
export LD_LIBRARY_PATH="$root/usr/lib/x86_64-linux-gnu${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}"
mime=$("$root/usr/bin/wl-paste" --list-types | grep -m1 -E '^image/') || { echo "no image on clipboard" >&2; exit 1; }
"$root/usr/bin/wl-paste" -t "$mime" \
| "$root/venv/bin/python" -c 'import sys,io; from PIL import Image;
Image.open(io.BytesIO(sys.stdin.buffer.read())).save(sys.stdout.buffer,"PNG")' \
| "$root/usr/bin/xclip" -selection clipboard -t image/png -i
EOF
chmod +x ~/.local/bin/xclip ~/.local/bin/kpaste
Usage: copy a screenshot in Windows, run kpaste, then /paste in Kiro.