Finding your Anaconda Python interpreter pathΒΆ
IDEs often require you to specify the path to your Python interpreter.
This path varies according to which operating system version and which Anaconda version you use, so you will need to search your file system to find the correct path to your Python interpreter.
You can search for the Python interpreter with your operating system’s file manager, such as File Explorer on Windows, Finder on macOS or Nautilus on Ubuntu Linux.
You can also use the command line to show the location of the Python interpreter in the active conda environment.
Windows:
From the Start Menu open the Anaconda Prompt.
If you want the location of a Python interpreter for a conda environment other than the root conda environment, run
activate environment-name
.NOTE: Replace
environment-name
with the name of the environment you wish to activate.Run
where python
.
macOS and Linux:
Open a Terminal window.
If you want the location of a Python interpreter for a conda environment other than the root conda environment, run
source activate environment-name
.NOTE: Replace
environment-name
with the name of the environment you wish to activate.Run
which python
.
EXAMPLES:
Windows 10 with Anaconda3 and username “jsmith”–
C:\Users\jsmith\Anaconda3\python.exe
.The Python image in a conda environment called “my-env” might be in a location such as
C:\Users\jsmith\Anaconda3\envs\my-env\python.exe
.macOS–
~/anaconda/bin/python
or/Users/jsmith/anaconda/bin/python
.Linux–
~/anaconda/bin/python
or/home/jsmith/anaconda/bin/python
.
Instead of anaconda
, the folder in your home directory might be named one of the following:
anaconda2
.anaconda3
.
If you have installed Miniconda instead of Anaconda, the folder might be named:
miniconda
.miniconda2
.miniconda3
.