CLAUDE_CODE_DISABLE_MOUSE_CLICKS also disables mouse drag-select, not just click-to-approve

Status Open
Maintainer reply None cached
Activity 3 comments · opened Jul 14, 2026

Description

CLAUDE_CODE_DISABLE_MOUSE_CLICKS=1 is documented as a way to stop stray terminal mouse clicks from being misinterpreted as approval of pending tool-permission prompts. In practice it works for that (verified empirically — a rejection click was correctly registered as a real "No", not an accidental approval), but it's an all-or-nothing toggle: it also disables normal mouse drag-to-select of terminal text, which is a separate and useful interaction.

Steps to reproduce

  1. Set export CLAUDE_CODE_DISABLE_MOUSE_CLICKS=1 and restart the terminal/session.
  2. Try to drag-select text in the terminal running Claude Code.
  3. Observe that drag-select no longer works, alongside click-to-approve being disabled.

Expected behavior

A way to disable mouse clicks being interpreted as permission-prompt approval, without disabling mouse drag-select entirely — these feel like they should be independently controllable (approval-click handling vs. general mouse passthrough).

Actual behavior

The single env var couples both behaviors, so fixing the accidental-approval risk means losing drag-select.

Additional context

Checked the current docs for a narrower/separate setting; found none — this appears to be a genuine gap rather than a missed config option.

View original on GitHub ↗

3 Comments

jjanuszkiewicz · 1 month ago

Like I commented in https://github.com/anthropics/claude-code/issues/70672#issuecomment-5347873174:

CLAUDE_CODE_DISABLE_MOUSE_CLICKS=1 disables WAY too much. Per the linked docs:

Set to 1 to disable click, drag, and hover handling [...] clicks to position the cursor, expand tool output, or open links.

This went all-or-nothing, while what was asked in https://github.com/anthropics/claude-code/issues/70672 was only preventing accidental menu navigation and the option choices (confirmations). For me personally accidental answers to interactive questions/confirmations/approvals is the biggest problem, I don't mind menu navigation.

Click/select text and opening links is still very useful and a hard blocker for me to enable this env var.

wellsdm2002 · 1 month ago

It does let you stop the click on menu issue w/o losing scrolling but it also breaks being able to highlight text and copy it, so still not a good solution.

wellsdm2002 · 1 month ago

Actually, Claude showed me that I can hold down shift and still select/highlight text to copy it so I guess I'm good.