How to resolve the issue of “conda is not recognized as an internal or external command” when inputting it into the command prompt?
If you encounter the error “not recognized as an internal or external command, operable program or batch file” when running the conda command on Windows, it may be due to the incorrect path setting for Anaconda or Miniconda. Please try to resolve this issue by following these steps:
- Ensure that Anaconda or Miniconda has been successfully installed. Make sure to take note of the installation path during the installation process.
- Open the command prompt (or Anaconda Prompt).
- Enter the following command to add the installation path of Anaconda or Miniconda to the environment variables (replace
with the actual installation path): - Add the Conda Scripts and Library bin directories to the PATH environment variable.
- For example, if Anaconda is installed in the directory C:\Anaconda3, the command would be:
- Add “C:\Anaconda3\Scripts” and “C:\Anaconda3\Library\bin” to the PATH environment variable.
- Close the command prompt and then open a new command prompt window.
- If you enter the conda command and no error message appears, it means the issue has been resolved.
Please note that if you are using PowerShell, you can replace “setx” in the command above with “$env:PATH += “
I hope this helps you!