Installation Guide

Learn how to install and configure conda on your system

guide

Installing and configuring Conda is a straightforward process that can be tailored to your operating system and workflow preferences. First, decide whether you want the full Anaconda distribution, which bundles around 150 scientific packages, or the lightweight Miniconda installer, which gives you just Conda and lets you add packages on demand.

Windows – Download the 64‑bit .exe from the Anaconda repository and run the installer. You can run it with administrator rights if you want Conda to be available system‑wide, or install it in a user‑local directory to avoid permission issues. During installation you can choose to add Conda to your PATH, but it is usually safer to let the installer create a shortcut and then run conda init to add Conda to your shell automatically.

macOS / Linux – Download the shell script, make it executable with chmod +x <script>, open a terminal, navigate to the download folder, and execute it with bash <script>. Follow the prompts to accept the license, choose an install location, and let the installer initialize Conda in your shell. After installation run conda init for the shell you use (bash, zsh, fish, etc.) so that Conda is available in new terminal sessions.

After installation, verify that Conda is available by running conda --version; you should see a version number such as 23.7.2. Keep Conda up to date with conda update conda. If you prefer to stay in the base environment, you can also run conda update -n base conda.


Environment Management

Conda’s core feature is environment isolation. Create a new environment with conda create -n myenv python=3.11, activate it using conda activate myenv, and install packages with conda install numpy pandas matplotlib. If you need packages from community channels, first add the channel with conda config --add channels conda-forge and then install from there. It is a good practice to set strict channel priority and disable auto‑activation of the base environment:

conda config --set channel_priority strict
conda config --set auto_activate_base false

The .condarc file in your home directory lets you set default channels, channel priority, and other preferences. A typical configuration might list conda-forge and defaults as channels, enforce strict channel priority, and disable auto‑activation of the base environment. This keeps your base environment clean and ensures reproducibility across projects.


Reproducibility & Cleanup

Export your environment to a YAML file with conda env export > environment.yml. The file includes the environment name and all dependencies, and can be shared or used to recreate the environment on another machine with conda env create -f environment.yml. Regularly clean up unused packages and environments with conda clean --all to keep your system tidy; this removes caches, unused packages, and tarballs.

If you encounter PATH issues, add the Conda binary directory (e.g., <install_path>/condabin) to your system PATH. Permission errors on Linux or macOS can be avoided by installing Conda in a user‑local directory rather than a system directory. Channel conflicts that result in UnsatisfiableError can often be resolved by removing conflicting channels or using the --freeze-installed flag.


Integration with Popular Tools

  • Jupyter – Install Jupyter in a dedicated environment and register the kernel with python -m ipykernel install --user --name myenv --display-name "Python (myenv)". This makes the environment available as a kernel in Jupyter notebooks.
  • VS Code – The Python extension automatically detects Conda environments, allowing you to run notebooks and scripts directly from the editor.

Further Reading

By following these steps, you’ll establish a robust Conda setup that supports reproducible scientific workflows, efficient package management, and smooth integration with your development tools.