PlainError

bash: command not found

Last checked 2026-11-02 · 3 fixes · reviewed answer

TL;DRThe bash shell could not locate the program or script you tried to run, which usually means the command is missing, misspelled, or not available in your current environment.

Most likely cause: The command or program is not installed on the system

Try first: Verify the exact command spelling

Likely causes

  1. The command or program is not installed on the systemmost likely
  2. Typo or incorrect command name in the script or terminalpossible
  3. The directory containing the command is not listed in the PATH environment variableless likely

How to fix it

Safest first: SafeChanges settingsDangerous
  1. Verify the exact command spellingSafe

    Double-check the command you entered or the line in your script for any typos.

  2. Check if the command existsSafe

    Run the type command to see if bash can find it anywhere.

    type yourcommand
  3. Install the missing packageChanges settings

    Use your system's package manager to install the program if it is available.

    sudo apt install packagename  (or equivalent for your distro)

    ⚠ This will modify your system by installing software.

If that didn't fix it

Run 'echo $PATH' to inspect the search path and compare it with the location of the command.

When to see a technician

If this error occurs inside a critical script or deployment pipeline, ask a developer or system administrator to review the environment setup.

Quick answers

What does bash: command not found mean?
The bash shell could not locate the program or script you tried to run, which usually means the command is missing, misspelled, or not available in your current environment.
What causes bash: command not found?
The command or program is not installed on the system. (most likely) Typo or incorrect command name in the script or terminal. (possible) The directory containing the command is not listed in the PATH environment variable. (less likely)
How do I fix bash: command not found?
Try these in order, safest first: 1. Verify the exact command spelling. 2. Check if the command exists. 3. Install the missing package.
What if that didn't fix it?
Run 'echo $PATH' to inspect the search path and compare it with the location of the command.
When should I see a technician?
If this error occurs inside a critical script or deployment pipeline, ask a developer or system administrator to review the environment setup.
Did this fix it? Report a problem

Related errors

All Coding errors →