claude-code - 💡(How to fix) Fix Warning 'Native installation exists but ~/.local/bin is not in your PATH' fires even when ~/.local/bin is in PATH

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…

Claude Code shows the following warning beneath the input prompt even when ~/.local/bin is already present in $PATH:

Native installation exists but ~/.local/bin is not in your PATH. Run: echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc

Root Cause

Claude Code shows the following warning beneath the input prompt even when ~/.local/bin is already present in $PATH:

Native installation exists but ~/.local/bin is not in your PATH. Run: echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc

Code Example

/Users/mozdzanowski/.local/bin
RAW_BUFFERClick to expand / collapse

Description

Claude Code shows the following warning beneath the input prompt even when ~/.local/bin is already present in $PATH:

Native installation exists but ~/.local/bin is not in your PATH. Run: echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc

Steps to reproduce

  1. Install Claude Code natively (binary at ~/.local/bin/claude)
  2. Add ~/.local/bin to PATH via ~/.zshenv (or ~/.zshrc / ~/.zprofile)
  3. Fully quit and relaunch VSCode
  4. Open a new terminal — echo $PATH confirms ~/.local/bin is present
  5. Run claude from that terminal
  6. Warning still appears beneath the input prompt

Expected behavior

Warning should not appear when ~/.local/bin is verifiably in $PATH.

Actual behavior

Warning appears regardless. Running the suggested fix command has no effect since the entry is already present.

Environment

  • macOS 25.5.0 (Darwin)
  • Shell: zsh
  • Terminal: VSCode built-in terminal
  • Claude Code launched as CLI from terminal (not VSCode extension)
  • ~/.local/bin confirmed in PATH via echo $PATH | tr ':' '\n' | grep local:
    /Users/mozdzanowski/.local/bin
  • Native binary confirmed at ~/.local/bin/claude

Notes

Debugging revealed that Claude Code's PATH check may be reading PATH from a different source than process.env.PATH (e.g. a freshly-spawned non-interactive shell, or a macOS system-level API). The terminal's PATH is correct; the discrepancy appears to be in how the check is performed internally.

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…

FAQ

Expected behavior

Warning should not appear when ~/.local/bin is verifiably in $PATH.

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 Warning 'Native installation exists but ~/.local/bin is not in your PATH' fires even when ~/.local/bin is in PATH