[BUG] Text cannot be copied from Claude Code's output using `Ctrl+Shift+C` or right-click context menu.

Status Open
Reported on v2.1.152
Maintainer reply None cached
Activity 41 comments · opened May 27, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Text cannot be copied from Claude Code's output.
Neither Ctrl+Shift+C, right-click context menu, nor middle-click (X primary selection) work.
Other CLI tools in the same terminal allow normal text selection and copy.

What Should Happen?

Text in the terminal output should be selectable and copyable using standard terminal copy methods (Ctrl+Shift+C, right-click, or mouse selection + middle-click).

Error Messages/Logs

Steps to Reproduce

  1. Open a terminal and run claude
  2. Send any prompt and wait for the response
  3. Try to select text in the response with the mouse
  4. Press Ctrl+Shift+C or right-click → no copy operation works
  5. Try mouse selection + middle-click → also does not work

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

2.1.152 (Claude Code)

Claude Code Version

2.1.152 (Claude Code)

Platform

Anthropic API

Operating System

Ubuntu/Debian Linux

Terminal/Shell

Other

Additional Information

Claude Code's TUI may be capturing mouse events or placing the terminal in a mode (e.g. raw mode or alternate screen) that interferes with normal text selection. This does not occur with other terminal-based AI tools.

View original on GitHub ↗

41 Comments

github-actions[bot] · 3 months ago

Found 3 possible duplicate issues:

  1. https://github.com/anthropics/claude-code/issues/61936
  2. https://github.com/anthropics/claude-code/issues/62462
  3. https://github.com/anthropics/claude-code/issues/62457

This issue will be automatically closed as a duplicate in 3 days.

  • If your issue is a duplicate, please close it and 👍 the existing issue instead
  • To prevent auto-closure, add a comment or 👎 this comment

🤖 Generated with Claude Code

thomasballinger · 3 months ago

What terminal emulator are you using? Use /tui default to change back to the version that allows native selection, but each terminal also has a button to press to enable this for that interaction: Terminal.app: Fn, iTerm2: option

Servo97 · 3 months ago

I see the same issue in terminator (ubuntu 24)

Sorrow321 · 3 months ago

Same issue

NeilGraham · 3 months ago

Same issue on Raspberry Pi 5 running DietPi (Debian)

fabian-lu · 3 months ago

same issue in my pycharm terminal on ubuntu

ulloacastillo · 2 months ago

try hold shift while dragging to select text, then copy whith ctrl+shift+c, this worked for me in ubuntu

larytet · 2 months ago

Workaround is in 62706

larytet · 2 months ago
try _hold shift while dragging to select text_, then copy whith ctrl+shift+c, this worked for me in ubuntu

I am pressing Shift this for two weeks. Annoying,

vandyahmadldm · 2 months ago

it's already fix?

jvanvolken · 2 months ago
1stvamp · 2 months ago

The linked workaround is a different issue to this was afaics, as this happens in a native tty, not on a remote or tmux session.
It didn't work for me.

DennisFaucher · 2 months ago

This is so dumb. Not being able to copy text when claude says "Run this command in another terminal".

I found a dumb workaround as claude -p creates text you can copy.

$ claude -n foobar -p "What is the meaning of life"
(The philosophical short answer: most traditions converge on something like connection, purpose, and growth — but the honest answer is that it's a question each person has to answer for themselves through how they live.)

$ claude --resume foobar -p "In what book was the answer 42?"
The Hitchhiker's Guide to the Galaxy by Douglas Adams. In the story, a supercomputer called Deep Thought spends 7.5 million years calculating the "Answer to the Ultimate Question of Life, the Universe, and Everything" — and the answer is 42. The catch: nobody remembers what the actual question was.

==========================================

claude --resume history -p "How to I name a session on startup, rename a session while in the session, resume that sesion later?"
Name on startup:

claude -n my-session-name

Rename while in a session:

/rename my-session-name

Resume later:

claude --resume my-session-name

Or run claude --resume with no argument to open an interactive picker and search by name.

larytet · 2 months ago

or


fix-tengu() {
    python3 -c "
import json, pathlib
p = pathlib.Path.home() / '.claude.json'
d = json.loads(p.read_text())
d['tengu_pewter_brook'] = False
p.write_text(json.dumps(d, indent=2))
print('tengu_pewter_brook set to false')
"
}

alias claude='fix-tengu && command claude'

On Mon, Jun 15, 2026 at 9:28 PM Dennis Faucher @.***>
wrote:

DennisFaucher left a comment (anthropics/claude-code#62699) <https://github.com/anthropics/claude-code/issues/62699#issuecomment-4711087863> This is so dumb. Not being able to copy text when claude says "Run this command in another terminal". I found a dumb workaround as claude -p creates text you can copy. $ claude -n foobar -p "What is the meaning of life" (The philosophical short answer: most traditions converge on something like connection, purpose, and growth — but the honest answer is that it's a question each person has to answer for themselves through how they live.) $ claude --resume foobar -p "In what book was the answer 42?" The Hitchhiker's Guide to the Galaxy by Douglas Adams. In the story, a supercomputer called Deep Thought spends 7.5 million years calculating the "Answer to the Ultimate Question of Life, the Universe, and Everything" — and the answer is 42. The catch: nobody remembers what the actual question was. ========================================== claude --resume history -p "How to I name a session on startup, rename a session while in the session, resume that sesion later?" Name on startup: claude -n my-session-name Rename while in a session: /rename my-session-name Resume later: claude --resume my-session-name Or run claude --resume with no argument to open an interactive picker and search by name. — Reply to this email directly, view it on GitHub <https://github.com/anthropics/claude-code/issues/62699?email_source=notifications&email_token=AABZHBOSSLTSVPI27MLBZN35AA54ZA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTINZRGEYDQNZYGYZ2M4TFMFZW63VHMNXW23LFNZ2KKZLWMVXHJLDGN5XXIZLSL5RWY2LDNM#issuecomment-4711087863>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AABZHBNFWPAK4BBNJYRZ7WT5AA54ZAVCNFSNUABFKJSXA33TNF2G64TZHM4TGNZSGUZTINZVHNEXG43VMU5TINJSHE2TSNBYGY42C5QC> . Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS <https://github.com/notifications/mobile/ios/AABZHBMOYVUOI4Q4VTKIV2L5AA54ZA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTINZRGEYDQNZYGYZ2M4TFMFZW63VHMNXW23LFNZ2KKZLWMVXHJKTGN5XXIZLSL5UW64Y> and Android <https://github.com/notifications/mobile/android/AABZHBNZ2SOXCMTSAOV6OEL5AA54ZA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTINZRGEYDQNZYGYZ2M4TFMFZW63VHMNXW23LFNZ2KKZLWMVXHJLTGN5XXIZLSL5QW4ZDSN5UWI>. Download it today! You are receiving this because you commented.Message ID: @.***>
diserere · 2 months ago
What terminal emulator are you using? Use /tui default to change back to the version that allows native selection, but each terminal also has a button to press to enable this for that interaction: Terminal.app: Fn, iTerm2: option

Yes, this workaround with default mode works for me. Ubuntu 26.04, ptyxis as terminal app, claude 2.1.191

ahik · 2 months ago

Same for me ;(

rahmanusta · 2 months ago

It cannot copy

MikkelStaalEggen · 2 months ago

Once CC is up and showing its interface, type this as a command inside CC:
/tui default
Then test: scroll with your normal mouse wheel, and try a plain mouse click-drag (no Shift needed) to select some text, then Ctrl+Shift+C.

qmaruf · 1 month ago

Fedora. Tilix. Same annoying issue.

Mil00Z · 1 month ago

Very bad issue, the trick to "hold" shift is ok for a little bit of text...

SebaViana · 1 month ago

Having this issue on GNOME Terminal 3.52.0

joestitty · 1 month ago

I cant seem to copy either from the textoutput of the terminal. I am using vscode btw.

larytet · 1 month ago

This works ``/tui default``

flaancs · 1 month ago

Same here, neither Ctrl+C nor Ctrl+Shift+C nor right-clicking works; sometimes one works, sometimes the other, sometimes neither. This happens to me with zsh on Debian 13.

tmortagne · 1 month ago

Same problem on Ubuntu 26.04 and claude code 2.1.178. Seems to work fine on Ubuntu 24.04.

To be precise, claude is claiming that it pasted something to the clipboard, but it's not the case. Thankfully the shift+select (indicated in the same message "in case it does not work") is working fine.

It seems to be, at least partly, specific to Ptyxis. This is the new terminal Ubuntu switched to compared to 24.04, and it works fine with others terminals like Kitty on Ubuntu 26.04.

<img width="3840" height="2336" alt="Image" src="https://github.com/user-attachments/assets/e9387289-4557-4046-a054-8a8871947f81" />

As indicated on other issues, and indicated when you select some text in claude, a possible workaround is to hold SHIFT while you select text which will more natively select the text from terminal point of view. That means that you can then use the usual way to copy text on Linux (middle mouse button, or CTRL+SHIT+C).

ignati4444-wq · 1 month ago

Fedora 44, who thought it was a brilliant idea to add a clippable interface to a terminal?
I can no longer reliably copy paste anything from the console.

myifaisal · 1 month ago

I was able to isolate the mouse selection / copy issue to the fullscreen TUI setting.

The issue occurs when this exists in ~/.claude/settings.json:

{
  "tui": "fullscreen"
}

Environment tested:

SHELL=/bin/bash
TERM=xterm-256color
Connection=SSH
OS=Ubuntu and AlmaLinux

Symptoms:

  • Mouse text selection does not work reliably inside Claude Code.
  • Copying selected terminal text fails or becomes inconsistent.
  • The same SSH client and terminal work normally outside Claude Code.

I tested this on both Ubuntu and AlmaLinux servers. After removing only "tui": "fullscreen" from ~/.claude/settings.json and restarting Claude Code, mouse selection/copy worked normally on both systems.

Workaround:

python3 - <<'PY'
import json, pathlib

p = pathlib.Path.home() / ".claude" / "settings.json"

data = {}
if p.exists():
    try:
        data = json.loads(p.read_text())
    except Exception:
        data = {}

data.pop("tui", None)

p.parent.mkdir(parents=True, exist_ok=True)
p.write_text(json.dumps(data, indent=2) + "\n")
print(p.read_text())
PY

I also confirmed the behavior by restoring the old config with "tui": "fullscreen"; the issue returned immediately. Removing it fixed the issue again.

This appears to be related to fullscreen TUI mode capturing or altering terminal mouse/input behavior in SSH sessions.

atomey · 1 month ago

Yep same problem, makes copying over SSH impossible. Removed on two different machines (Debian and Ubuntu) over SSH and now works fine copying and performance is much better also.

In my case, connecting with Terminal (2.14) on macOS Sequoia SSH -> Debian or Ubuntu boxes with CC installed with this same "tui": "fullscreen" in settings.

dragosb0000 · 1 month ago
"tui": "fullscreen"

Deleting this sorted the problem for me on Mac. Thank you!

sumanmummaneni3 · 1 month ago

I also see the /copy command is also not working Ubuntu 26.04 LTS. This is really annoying, as a work around I am try to use the Claude app that is available for Ubuntu.
I see this issue is specific to claude code running in the terminal. When I open a new tab in the same terminal copy work.
Some thing is not working in claude.

Ubuntu version

$ lsb_release -a

No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 26.04 LTS
Release: 26.04
Codename: resolute

sumanmummaneni3 · 1 month ago

The fix that I am using for now is to use tmux configured with script as given below. Able to copy using Shift+Mouse and Shift + ctrl + c

!/bin/bash

# Name of your automated tmux session
SESSION_NAME="claude-agents"

# Enable the multi-agent team environment flag
export CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1

# Check if we are already inside a tmux session
if [ -z "$TMUX" ]; then
    # 1. Start a new detached tmux session with the clipboard option enabled
    tmux new-session -d -s "$SESSION_NAME" -x "$(tput cols)" -y "$(tput lines)"

    # 2. Apply clipboard and OSC 52 configuration overrides
    tmux set-option -g set-clipboard on
    tmux set-option -ga terminal-override 'vte*:OSC=52'
    tmux set-option -ga terminal-override 'xterm*:OSC=52'

    # 3. Start first agent in Left Pane (Forcing classic inline text via env var)
    tmux send-keys -t "$SESSION_NAME" "CLAUDE_CODE_NO_FLICKER=0 claude" C-m

    # 4. Split the window vertically (creating the right pane)
    tmux split-window -h -t "$SESSION_NAME"

    # 5. Start second agent in Right Pane (Forcing classic inline text via env var)
    tmux send-keys -t "$SESSION_NAME" "CLAUDE_CODE_NO_FLICKER=0 claude" C-m

    # 6. Balance focus back to the left pane
    tmux select-pane -t "$SESSION_NAME":0.0

    # 7. Attach to the newly created session
    tmux attach-session -t "$SESSION_NAME"
else
    # If you are already inside tmux, just split the current active window
    tmux set-option -g set-clipboard on
    tmux set-option -ga terminal-override 'vte*:OSC=52'
    tmux set-option -ga terminal-override 'xterm*:OSC=52'

    tmux send-keys "CLAUDE_CODE_NO_FLICKER=0 claude" C-m
    tmux split-window -h
    tmux send-keys "CLAUDE_CODE_NO_FLICKER=0 claude" C-m
    tmux select-pane -t 0
fi
motaamneh · 1 month ago

I had the same issue on ubuntu 26, here's what I did and it worked

  1. Open ~/.claude/settings.json using this command vim ~/.claude/settings.json
  2. Locate and remove {"tui": "fullscreen"} from the settings press i to edit remove {"tui": "fullscreen"} then press :wq
  3. Restart Claude Code.
lsc-dvc · 1 month ago

Had this same problem under ubuntu xfce, also solved by running /tui default (this will update the settings file and change it for the current session as well, without needing to restart claude).
This also prevents copying the login URL when running /login (which i worked around by using claude setup-token, which was fortunately not likewise broken).

hoangtaiki · 1 month ago
python3 - <<'PY' import json, pathlib p = pathlib.Path.home() / ".claude" / "settings.json" data = {} if p.exists(): try: data = json.loads(p.read_text()) except Exception: data = {} data.pop("tui", None) p.parent.mkdir(parents=True, exist_ok=True) p.write_text(json.dumps(data, indent=2) + "\n") print(p.read_text()) PY

Working solution when I ssh in Linux from MacOS using Terminal

tylerkastner · 1 month ago
Had this same problem under ubuntu xfce, also solved by running /tui default (this will update the settings file and change it for the current session as well, without needing to restart claude). This also prevents copying the login URL when running /login (which i worked around by using claude setup-token, which was fortunately not likewise broken).

This worked for me on MacOS

AleksKotrulev · 1 month ago

I had a similar issue, running claude code in any terminal in intelliJ or rider - Selecting a section would produce a message saying that selection was auto-copied, however when i hit paste, it would be a different section, mostly happens when i need to scroll for longer messages.

THE FIX: Go to the global config of claude, in settings.json and remove {"tui": "fullscreen"} line

Hope this helps others

yhojann-cl · 1 month ago

Confirmed on Ubuntu 26.04 LTS, can not copy using ctrl + shift + c, or right click on terminal. In others agents like as codex works fine but in claude code fails copy. I had to take a screenshot of the result and pass it to another AI to get it in plain text format. The /copy command doesn't copy the result to the clipboard either; it's probably because Wayland handles this differently. Even if it did work, it wouldn't allow me to copy previous results or text.

1stvamp · 1 month ago

If anyone else uses Wezterm here's a solution that keeps some of the useful fullscreen TUI features like being able to click on shell sections to expand them etc: https://www.1stvamp.org/mouse-selection-in-wezterm-when-claude-code-grabs-the-mouse/

tmortagne · 1 month ago

Note: the following fixed it for me on Ubuntu 26.04

sudo apt install wl-clipboard xclip

I used the Debian package, I so I guess the package could be improved to add those dependencies...

csbraga1995-cmd · 1 month ago

Eu resolvi esse problema com esse comando no terminal antes de abrir a claude

CLAUDE_CODE_DISABLE_MOUSE=1

nikolareljin · 8 days ago

Same issue

had to do /tui default and stop using in full-screen mode