Skip to content

Client Can't Find forge

  • Running forge in a terminal returns command not found: forge or forge: command not found.
  • Your MCP client reports “spawn failed” or a similar error when trying to start the Forge server.
  • which forge returns no output.

CauseIndicator
Forge has not been installedwhich forge returns nothing
Binary is installed but not in PATHBinary exists at a known path but forge fails
Shell profile not sourcedWorks in a new terminal but not an existing one
Wrong shell (zsh vs bash)PATH set in .bashrc but running zsh
macOS Gatekeeper quarantine”cannot be opened” error — see Binary Won’t Run on macOS

Terminal window
which forge
ls ~/.local/bin/forge 2>/dev/null || echo "not at ~/.local/bin"
ls /usr/local/bin/forge 2>/dev/null || echo "not at /usr/local/bin"

If none of these paths have the binary, proceed to Step 2. If the binary exists but forge still fails, skip to Step 3.

Download the binary for your platform from https://forge.ironpinelabs.com/docs/getting-started/install-forge/. Installation is a single file copy:

macOS (Apple Silicon):

Terminal window
curl -fsSL https://downloads.forge.ironpinelabs.com/latest/forge-macos-aarch64 -o forge
chmod +x forge
sudo mv forge /usr/local/bin/forge

macOS (Intel):

Terminal window
curl -fsSL https://downloads.forge.ironpinelabs.com/latest/forge-macos-x86_64 -o forge
chmod +x forge
sudo mv forge /usr/local/bin/forge

Linux (x86-64):

Terminal window
curl -fsSL https://downloads.forge.ironpinelabs.com/latest/forge-linux-x86_64 -o forge
chmod +x forge
sudo mv forge /usr/local/bin/forge

Linux (ARM64):

Terminal window
curl -fsSL https://downloads.forge.ironpinelabs.com/latest/forge-linux-aarch64 -o forge
chmod +x forge
sudo mv forge /usr/local/bin/forge

Verify the SHA-256 checksum from https://downloads.forge.ironpinelabs.com/latest/latest.json before running.

If the binary is installed but not in your PATH, add the directory containing it to your shell profile.

For ~/.local/bin/forge (common for user-local installs):

bash (edit ~/.bashrc or ~/.bash_profile):

Terminal window
export PATH="$HOME/.local/bin:$PATH"

zsh (edit ~/.zshrc):

Terminal window
export PATH="$HOME/.local/bin:$PATH"

fish (edit ~/.config/fish/config.fish):

Terminal window
set -gx PATH $HOME/.local/bin $PATH

After editing, reload your shell profile:

Terminal window
source ~/.bashrc # bash
source ~/.zshrc # zsh

Or open a new terminal window.

Terminal window
which forge
forge --version

Expected output:

/usr/local/bin/forge
forge 1.3.0

If your MCP client still cannot find forge after PATH is set, use the absolute path in .mcp.json rather than relying on PATH resolution:

{
"mcpServers": {
"forge": {
"command": "/usr/local/bin/forge",
"args": ["serve", "/path/to/your/repo"]
}
}
}

Replace /usr/local/bin/forge with the output of which forge. GUI applications (like VS Code) may launch with a different PATH than your terminal.


Contact support at support@forge.ironpinelabs.com if:

  • You have placed the binary in a standard location (/usr/local/bin) and it still returns command not found.
  • You are on a managed machine where sudo mv is not available and your organization controls PATH.

Include the output of:

Terminal window
echo $PATH
uname -a
ls -la /usr/local/bin/forge 2>/dev/null || echo "not found"