claude-code - 💡(How to fix) Fix Login prompt does not accept paste input on Linux/Ubuntu terminals [9 comments, 10 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#47728Fetched 2026-04-15 06:43:57
View on GitHub
Comments
9
Participants
10
Timeline
18
Reactions
5
Author
Timeline (top)
commented ×9labeled ×4cross-referenced ×2subscribed ×2

The /login (or claude login) interactive prompt that asks users to paste their authorization code does not accept paste input on Linux/Ubuntu terminals. Typed input works fine — only paste is broken.

Root Cause

The /login (or claude login) interactive prompt that asks users to paste their authorization code does not accept paste input on Linux/Ubuntu terminals. Typed input works fine — only paste is broken.

RAW_BUFFERClick to expand / collapse

Description

The /login (or claude login) interactive prompt that asks users to paste their authorization code does not accept paste input on Linux/Ubuntu terminals. Typed input works fine — only paste is broken.

Steps to Reproduce

  1. Run claude on a remote Ubuntu machine (via SSH)
  2. Run /login
  3. Open the OAuth URL in a browser and copy the authorization code
  4. Attempt to paste the code into the "Paste code here if prompted >" prompt

Expected Behavior

The pasted text should appear in the input field, same as typed text.

Actual Behavior

Paste does nothing. The following paste methods were all tried and none worked:

  • Right-click paste
  • Shift+Insert
  • Ctrl+Shift+V
  • Terminal paste via SSH client (Cmd+V from macOS SSH client)

All of these paste methods work correctly:

  • In the same terminal outside of Claude Code
  • Inside Claude Code in the normal chat prompt
  • Just not in the login/auth code prompt specifically

Environment

  • OS: Ubuntu (remote, accessed via SSH)
  • Claude Code CLI

extent analysis

TL;DR

The issue is likely due to a terminal mode or input handling difference in the /login prompt, and a workaround may involve modifying the input handling or using an alternative input method.

Guidance

  • Investigate the input handling in the /login prompt to see if it's using a different terminal mode or input processing than the normal chat prompt.
  • Try using echo to pipe the authorization code into the /login prompt, e.g., echo "auth_code" | claude login, to see if it bypasses the input issue.
  • Check if there are any environment variables or configuration options that affect the input behavior in the /login prompt.
  • Consider using a tool like expect to automate the input process and see if it can successfully paste the authorization code.

Example

No code snippet is provided as it's not clearly supported by the issue, but the echo pipe suggestion above can be explored further.

Notes

The issue seems specific to the /login prompt and Linux/Ubuntu terminals, so any solution or workaround may need to account for these factors. Additionally, the fact that paste works outside of the /login prompt and in other parts of the application suggests that the issue is isolated to this specific input field.

Recommendation

Apply workaround: The echo pipe method or using a tool like expect may provide a temporary solution until the root cause is identified and fixed.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix Login prompt does not accept paste input on Linux/Ubuntu terminals [9 comments, 10 participants]