Check what conda environment is currently activated Check what conda environment is currently activated bash bash

Check what conda environment is currently activated


When a conda environment is activated, it will export following related environment variables:

  • $CONDA_DEFAULT_ENV, name of current activated env
  • $CONDA_PREFIX, path to the current activate env


The current environment is stored in the environment variable, $CONDA_DEFAULT_ENV. So,

echo $CONDA_DEFAULT_ENV

will give the name of the current conda environment.


conda info --envs

This will print all the conda environments. The current environment will have an asterisk( * ) in front of it's name.