Windows – install method keeps flipping (unknown ↔︎ npm-global) despite native install; want stable native setup
Hello,
I’m having trouble with Claude Code on Windows — it’s not detecting the correct installation config.
Env
Windows (PowerShell + Git Bash installed)
Node at C:\Program Files\nodejs\node.exe
Git Bash at C:\Program Files\Git\bin\bash.exe
Claude Code 1.0.72
What I need
A clean, stable native install (only C:\Users\<username>\.local\bin\claude.exe on PATH), and claude doctor recognizing the install method consistently (no “unknown” / mismatch). Also: confirm whether the “unknown” detection is a known bug and how to suppress it.
What I did (critical steps & results)
Reinstalled via npm:
npm i -g @anthropic-ai/claude-code@latest
where claude -> C:\Users\<username>\AppData\Roaming\npm\claude(.cmd)
claude --version -> 1.0.72
Ran native installer from CLI:
claude install
Output: "Claude Code successfully installed! Location: C:\Users\<username>\.local\bin\claude.exe"
claude doctor --debug (immediately after #2):
Currently running: npm-global (1.0.72)
Invoked: C:\Users\<username>\AppData\Roaming\npm\node_modules\@anthropic-ai\claude-code\cli.js
Config install method: native
claude update --debug:
Warns of mismatch (config expects native, currently running npm-global).
Then it flips config to global, tries npm view, and fails (code 1, empty stderr).
Manual npm view @anthropic-ai/claude-code version works → 1.0.72.
npm whoami → ENEEDAUTH (not logged in).
Ran claude migrate-installer (success), restarted shell.
Now:
doctor:
Currently running: unknown (1.0.72)
Invoked: C:\Users\<username>\.claude\local\node_modules\@anthropic-ai\claude-code\cli.js
Config install method: local
update --debug:
Installation type: unknown
Config install method: local
Latest version from npm: 1.0.72
"Claude Code is up to date (1.0.72)"
Current symptoms
doctor keeps reporting unknown or npm-global while config says native or local.
update sometimes uses npm even when config says native/local.
I want a single canonical native install and a consistent doctor result.
Questions
What’s the supported way to reset so only the native binary is on PATH and recognized (no npm/local shims)?
Should claude update ever call npm when config is native/local? If not, how do I prevent that?
Is the “Currently running: unknown” output a known issue? If so, any workaround to verify I’m truly on native (e.g., a specific path/check)?
Thanks!
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗