[BUG] winget install succeeds but fails to create link — binary stranded in WinGet packages cache
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?
winget install Anthropic.ClaudeCode reported "Successfully installed" and downloaded the binary (240MB), but:
- WinGet\Links\claude.exe — not created
- ~\.local\bin\claude.exe — not created
- ~\.local\bin was already in PATH
The binary was stranded at:
%LOCALAPPDATA%\Microsoft\WinGet\Packages\Anthropic.ClaudeCode_Microsoft.Winget.Source_8wekyb3d8bbwe\claude.exe
What Should Happen?
Claude Code should create symlinks or copies at WinGet\Links\claude.exe or ~/.local/bin/claude.exe so that the CLI is on PATH and usable after winget install, not leave the binary only in the package cache.
Error Messages/Logs
Steps to Reproduce
- On Windows (PowerShell), run: winget install Anthropic.ClaudeCode
- Wait for installation to succeed ("Successfully installed")
- Confirm that no claude.exe is found in WinGet\Links or ~/.local/bin
- Check %LOCALAPPDATA%\Microsoft\WinGet\Packages\Anthropic.ClaudeCode_Microsoft.Winget.Source_8wekyb3d8bbwe\ for a stranded claude.exe binary
Claude Model
_No response_
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
2.1.168
Platform
Other
Operating System
Windows
Terminal/Shell
PowerShell
Additional Information
Workaround: Manually copy the binary to ~/.local/bin/claude.exe or to a directory in PATH, e.g.:
powershell
Copy-Item "$env:LOCALAPPDATA\Microsoft\WinGet\Packages\Anthropic.ClaudeCode_Microsoft.Winget.Source_8wekyb3d8bbwe\claude.exe" "$env:USERPROFILE\.local\bin\claude.exe"
Related: #27867
3 Comments
Just ran into the same problem. In my case it was from running
winget upgrade Anthropic.ClaudeCodeon a working installation. ClaudeCode CLI suggests running this command to you every time the installed version is out of date.Performing the same workaround from the initial comment fixed my Claude cli.
Happened to me today.
I confirm it also affects my installation