[BUG] OAuth login flow gives no feedback when manual code paste is required — "if prompted" misleads users

Open 💬 3 comments Opened Jun 22, 2026 by nettsite

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?

Here's a bug report you can file:

---

Title: OAuth login flow gives no feedback when manual code paste is required — "if prompted" misleads users

Environment:

  • Claude Code (latest)
  • Server accessed via SSH from a separate workstation (server has internet access, no local browser)
  • Browser opened on workstation, not on the server running Claude Code
  • OS: Linux server

Description:

When running /login on a remote server accessed via SSH, the OAuth flow opens a URL which is visited in a browser on a separate workstation. The browser completes the OAuth authorization and displays an "Authentication Code" page at platform.claude.com/oauth/code/callback with the message "Paste this into Claude Code".

However, the Claude Code terminal shows only:

Paste code here if prompted >

...and then waits silently. The phrase "if prompted" strongly implies this step is optional or only needed in certain edge cases. There is no explicit prompt, no instruction to paste the code, and no indication that this is a required step to complete authentication.

Steps to reproduce:

  1. SSH into a remote Linux server
  2. Run claude /login
  3. Copy the authorization URL and open it in a browser on a different machine
  4. Complete OAuth authorization — browser shows "Authentication Code" page with a code
  5. Observe that Claude Code terminal shows Paste code here if prompted > but gives no further guidance

Expected behaviour:

Either:

  • The terminal should explicitly prompt the user to paste the code, e.g. Please paste the authentication code from your browser here >
  • Or the "if prompted" text should be removed/replaced with a clear instruction that pasting is always required when the browser is on a different machine

Actual behaviour:

The terminal waits silently with misleading "if prompted" text. The user has no indication they need to paste the code. Pasting the code and pressing Enter does complete authentication successfully, but this is not discoverable.

Impact:

Users attempting to authenticate Claude Code on a remote server from a browser on their workstation will be stuck with no clear path forward, despite the authentication flow having technically succeeded on the browser side.

---

Feel free to add your Claude Code version (claude --version) before filing.

What Should Happen?

Either:

  • The terminal should explicitly prompt the user to paste the code, e.g. Please paste the authentication code from your browser here >
  • Or the "if prompted" text should be removed/replaced with a clear instruction that pasting is always required when the browser is on a different machine

Error Messages/Logs

Steps to Reproduce

  1. SSH into a remote Linux server
  2. Run claude /login
  3. Copy the authorization URL and open it in a browser on a different machine
  4. Complete OAuth authorization — browser shows "Authentication Code" page with a code
  5. Observe that Claude Code terminal shows Paste code here if prompted > but gives no further guidance

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

2.1.185 (Claude Code)

Platform

Other

Operating System

Ubuntu/Debian Linux

Terminal/Shell

Other

Additional Information

_No response_

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗