The Conda workflow for managing environments and packages begins by creating a new environment with
conda create --name myenv python=3.10
to isolate dependencies and avoid project conflicts. Activate it using
conda activate myenv
, then install necessary packages like NumPy, Pandas, or Matplotlib with
conda install
. You can also use channels like
conda-forge
for additional packages. Use
conda list
to view installed packages and
conda env export > environment.yml
to back up or share your setup. When finished, deactivate the environment with
conda deactivate
, and optionally remove it using
conda remove --name myenv --all
. You can also list all environments with
conda env list
or clone one with
conda create --name newenv --clone myenv
.

Conda Workflow for Working with Environments and Packages
Step 1: Create a New Environment
Use this to isolate dependencies for each project.
conda create --name myenv python=3.10
-
myenv
= Name of your environment -
python=3.10
= Specific Python version (optional)
This prevents conflicts between projects.
Step 2: Activate the Environment
conda activate myenv
- This switches your terminal or Anaconda Prompt into the new environment.
Now all packages you install will only apply to this environment.
Step 3: Install Packages into the Environment
conda install numpy pandas matplotlib
- Installs packages like NumPy, Pandas, and Matplotlib.
You can also install from specific channels:
conda install -c conda-forge seaborn
Step 4: List Packages and Export Environment
Check which packages are installed:
conda list
Export the environment for sharing or backup:
conda env export > environment.yml
Useful for version control and reproducibility.
Step 5: Deactivate the Environment
conda deactivate
- This returns you to the base (default) environment.
Step 6: Remove an Environment (Optional Cleanup)
To delete an environment completely:
conda remove --name myenv --all
Do this when you're done with a project or want to clean up disk space.
Bonus Tips
- List all environments:
conda env list
- Clone an environment:
conda create --name newenv --clone myenv


