Where Is Claude Code Installed on Mac, Windows, and Linux?
If you used the official native installer, Claude Code is installed at ~/.local/bin/claude on macOS and Linux, and %USERPROFILE%\.local\bin\claude.exe on Windows. The actual program files are stored in ~/.local/share/claude/versions/.
If you installed with Homebrew, npm, or WinGet, the location is different. This article shows how to find where Claude Code is installed on your computer, the path for each install method, and where its config files are kept.
How to find where Claude Code is installed
The fastest way is to ask your terminal where the claude command comes from.
On macOS, Linux, or WSL:
which claude
On Windows PowerShell:
Get-Command claude
On my Mac, the output looks like this:
$ which claude
/Users/nathan/.local/bin/claude
To see if you have more than one copy installed, use which -a claude. Multiple results usually mean you installed Claude Code twice, for example with both npm and the native installer.
For a full report, run:
claude doctor
It shows your install method, version, auto-update status, and any problems with your setup.
Native installer location
The native installer is the recommended way to install Claude Code. It creates two things:
| OS | Launcher | Program files |
|---|---|---|
| macOS / Linux / WSL | ~/.local/bin/claude | ~/.local/share/claude/versions/ |
| Windows | %USERPROFILE%\.local\bin\claude.exe | %USERPROFILE%\.local\share\claude\ |
On macOS and Linux, ~/.local/bin/claude is a shortcut (a symlink) that points to the current version inside the versions/ folder:
$ ls -la ~/.local/bin/claude
~/.local/bin/claude -> ~/.local/share/claude/versions/2.1.296
Each update downloads a new version into versions/. Claude Code keeps the two newest versions and deletes older ones automatically.
If your terminal says claude: command not found after installing, it means ~/.local/bin isn’t in your PATH yet. Open a new terminal window first. If that doesn’t work, add this line to your ~/.zshrc or ~/.bashrc:
export PATH="$HOME/.local/bin:$PATH"
Homebrew, npm, and WinGet locations
If you used a package manager, it decides the install location:
- Homebrew (
brew install --cask claude-code): the command is linked into Homebrew’sbinfolder, which is/opt/homebrew/bin/claudeon Apple Silicon Macs and/usr/local/bin/claudeon Intel Macs - npm (
npm install -g @anthropic-ai/claude-code): the package goes into npm’s global folder. Runnpm root -gto see where that is on your machine - WinGet (
winget install Anthropic.ClaudeCode): runGet-Command claudein PowerShell to see the path
Note that Homebrew and WinGet installs don’t update automatically. You need to run brew upgrade claude-code or winget upgrade Anthropic.ClaudeCode yourself.
Where are the config files?
The program files and your personal data are kept separately. No matter how you installed Claude Code, your settings and history live in your home folder:
| Path | What’s inside |
|---|---|
~/.claude/ | Settings, skills, plugins, session history, and memory |
~/.claude.json | Account details, MCP servers, and per-project state |
These are covered in more detail in where is the Claude Code settings.json file and where Claude Code sessions are stored.
How to check your Claude Code version
Run this command in your terminal:
claude --version
The output shows the version number:
2.1.296 (Claude Code)
To update a native install right away instead of waiting for the background update, run claude update.
How to uninstall Claude Code
To remove a native installation on macOS or Linux, delete the launcher and the program files:
rm -f ~/.local/bin/claude
rm -rf ~/.local/share/claude
On Windows PowerShell:
Remove-Item -Path "$env:USERPROFILE\.local\bin\claude.exe" -Force
Remove-Item -Path "$env:USERPROFILE\.local\share\claude" -Recurse -Force
For other install methods, use the package manager’s uninstall command, such as brew uninstall --cask claude-code or npm uninstall -g @anthropic-ai/claude-code.
Uninstalling doesn’t remove your settings and history. If you want a completely clean removal, also delete ~/.claude and ~/.claude.json. Be careful, because this permanently deletes all your settings, MCP servers, and past sessions.
Conclusion
Run which claude (or Get-Command claude on Windows) to find where Claude Code is installed. With the native installer, that’s ~/.local/bin/claude, pointing to the program files in ~/.local/share/claude/versions/.
Your settings and history are always kept separately in ~/.claude/.