Multiple Python versions on Ubuntu 20.04
Last modified on July 24, 2026 • 1 min read • 37 wordsAdding alternative – mostly older – Python versions to your operating system is often necessary to run legacy code.

Adding a new python version to Ubuntu 20.04 (for my system it is the 3rd version after 2.7 and 3.8):
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3.6 3
To change system-wide between python versions:
sudo update-alternatives --config python