zoxide command not found - How to Fix
If you're seeing "zoxide command not found" after installation, this guide will help you troubleshoot and fix the issue.
Common Causes
The "command not found" error typically occurs due to one of these reasons:
- zoxide is not in your PATH
- Shell configuration not loaded
- Installation didn't complete successfully
- Wrong installation method for your system
Solution 1: Check Installation
First, verify that zoxide is actually installed:
If zoxide is not found, you need to reinstall it. See the installation guide for your platform.
Solution 2: Add to PATH
Linux / macOS
If zoxide is installed but not in PATH, add it manually:
For Cargo installation:
For manual installation:
Windows
For Cargo installation:
For manual installation:
Restart your terminal after modifying PATH.
Solution 3: Verify Shell Configuration
Make sure zoxide is initialized in your shell configuration file:
Bash (~/.bashrc):
Zsh (~/.zshrc):
Fish (~/.config/fish/config.fish):
PowerShell ($PROFILE):
After adding the configuration, reload your shell:
- Bash/Zsh:
source ~/.bashrcorsource ~/.zshrc - Fish:
source ~/.config/fish/config.fish - PowerShell:
. $PROFILE
Solution 4: Check Installation Method
Using Homebrew (macOS)
If installed via Homebrew, make sure Homebrew is in your PATH:
Using Scoop (Windows)
Scoop should automatically add programs to PATH. If not working:
Using Cargo
Verify Cargo is installed and in PATH:
Solution 5: Test in New Terminal
Sometimes the PATH changes don't take effect in the current terminal. Try:
- Close your current terminal
- Open a new terminal window
- Test zoxide again:
Quick Diagnostic Commands
Run these commands to diagnose the issue:
Still Not Working?
If none of the above solutions work:
- Reinstall zoxide using the recommended method for your platform
- Check system logs for installation errors
- Verify your shell is compatible (bash, zsh, fish, PowerShell)
- Check permissions - make sure zoxide binary is executable:
Prevention
To avoid this issue in the future:
- Use package managers (Homebrew, Scoop) when possible
- Always add installation directories to PATH immediately
- Test installation right after completing it
- Keep your shell configuration files organized