how to get out of an environment in python command prompt code example Example 1: deactivate venv deactivate venv Example 2: deactive venv $ deactivate