[Solved] Conda is not recognized as an internal or external command

What is an Anaconda?

Anaconda is an open-source distribution platform of Python and R programming languages. It is used to manage and deploy packages for different projects related to Artificial Intelligence, Data Science, and Machine Learning Applications. Its distribution package is compatible with Windows, Linux, and macOS platforms. You can access and use Anaconda from the command line and also from Anaconda Navigator. Anaconda Navigator is a graphical user interface platform to access anaconda functions.

You are here means you must be facing a “Conda is not recognized as an internal or external command, operable program or batch file” error while using the anaconda command. Go through this article thoroughly to understand the reasons behind this error message and possible solutions.

Conda is not recognized as an internal or external command, operable program or batch file" error

Why you are getting “Conda is not recognized as an internal or external command” error message

There are following three possible reasons for this error message. Let’s understand one by one.

1. Anaconda application is not installed on your system.

The first thing is to check whether you have installed Anaconda on your system or not. If the Anaconda application is not installed on your system then of course you will get this error message because you are trying to access something that is not available on the system itself.

You can use a control panel to check if Anaconda is installed on your system or not. If you have installed Anaconda on your system then move to the next solution.

2. Wrong or missing executable location path from a system environment variable.

If you have installed the Anaconda application then check the Path environment values and make sure the correct value of the Anaconda executable path is available.

Enter the following command on the command prompt to get values of a Path environment variable.

Echo %PATH%

3. Conflict with other applications environment variable

It’s a very rare scenario but sometimes environment variable of other applications may result in improper functioning of the Anaconda application.

Check other installed applications once and make sure they are not causing any conflict with the Anaconda executable.    

Solutions for Conda is not recognized as an internal or external command.

Here we are assuming that you have successfully installed the required version of Anaconda on your system. If not please install it before moving further.

There are three possible solutions that you can use to get rid of this error message

1. Set environment variable from the command prompt

You can always set the environment variable from the command prompt as shown below:

Step 1: Open the command prompt

Step 2: Copy the path of the installed anaconda application from your system

Step 3: Set the value of anaconda executable location in the system path variable as shown below

Set environment variable on command prompt

Step 4: Execute the required anaconda command.

Note:

This setting is applicable for particular command prompt instances. If you open another command prompt then you need to set the required environment variable again.

2. Add executable path to a system environment variable

Instead of setting the environment variable on the command prompt, you can directly add it to the system environment variable using a control panel. When you add this path value to the system environment variable then it will be applicable to all the users available on the system.

Follow the below stepwise procedure to add an anaconda executable path to a system environment variable.

Step 1:  Go to Control Panel — > System and Security — > System and select Advanced System Settings as shown below

[Solved] Conda is not recognized as an internal or external command

Step 2: In System Properties window, select Advanced section and click on Environment Variables option to open environment variable section.

Environment Variable

Step 3:

The environmental variable window consists of two sections, the user variable and the system variable.

Here we will set the required value of the Anaconda application executable on the system variable so that this configuration will be applicable for all the users of the system.

When you install the Anaconda application, all the required executable gets added to the Scripts folder of Anaconda installation.

Add path up to scripts folder of anaconda in the path variable value as shown below and click ok button.

Set anaconda scripts executable environment variable

Note:  After changing the environment variable value, make sure to open a new command prompt to execute the conda command, or else you will again get the “conda is not recognized as an internal or external command” error message.

3. Use the anaconda command prompt

Instead of using the system command prompt, you can directly use the Anaconda command prompt as shown below to access Anaconda functionality.

Anaconda command prompt

In this case, you don’t need to set anaconda executable environment variable.

You can directly access the Anaconda command prompt from the start menu by searching Anaconda in the search box.

Note:

At the time of Anaconda installation, in the Advanced Installation Options if you select the “Add Anaconda 3 to the system PATH environment variable” option then installable automatically sets the required environment variable. You don’t need to set it explicitly as explained above.

Add anaconda3 to the system PATH environment variable

Final Thoughts:

In this article, we have learned three different methods that we can follow to get rid of the “Conda is not recognized as an internal or external command, operable program or batch file” error message.

It’s up to you which approach to follow based on your convenience. Here at Technolads we recommend to use Anaconda command prompt instead of setting environment variable to avoid conflict with other applications.

Finally, we hope you can resolve the error message and be able to use the required anaconda functionality. Please share your views and experience in the comment section or you can reach out to us using the contact form.

Leave a Comment