Do these 3 things before closing this tab:
1Clear out junk files and repair common Windows errors2Fix the driver behind crashes, sound loss and screen glitches3Repair Windows errors before they cause bigger problemsSome links on this page are affiliate links: if you buy through them we may earn a commission, at no extra cost to you.
Install Python 3 through the channel supported by your operating system: use dnf (or yum on older CentOS releases) on CentOS-family systems, apt on Ubuntu, and the official Python Install Manager on Windows. Verify the command-line version, then use a virtual environment for each project so its packages stay separate from operating-system files.
Choose the installation method for your operating system
| Operating system | Installation channel | Typical command | Version command |
|---|---|---|---|
| CentOS-family Linux | System package manager: DNF on current systems; YUM on older releases | sudo dnf install python3 |
python3 --version |
| Ubuntu | APT repositories | sudo apt install python3 |
python3 --version |
| Windows | Python Install Manager from python.org or Microsoft Store | Install the manager, then use its runtime commands | py --version |
These package-manager commands install the version offered for that particular operating-system release and its enabled repositories. They do not guarantee the newest upstream Python minor version. If you specifically need a newer release, check the repository or runtime support for your exact OS edition rather than replacing a system interpreter blindly.
Install Python 3 on CentOS or another CentOS-family system
Install the repository-supported Python
Current CentOS-family systems use DNF. In a terminal, run:
sudo dnf install python3
python3 --version
Accept the package transaction when prompted. A successful version check prints a Python 3 version. The exact minor version depends on the release and repositories enabled on that machine.
#1 Best Overall
On older CentOS releases where dnf is not available, the equivalent package operation is commonly done with YUM:
sudo yum install python3
python3 --version
The precise package name and available version can vary by release. Python’s Unix documentation groups CentOS with Fedora and RHEL; follow the package channels supported by the specific system.
Add pip and wheel when needed
CentOS and RHEL do not offer pip or wheel in their core repositories, according to the Python Packaging Authority; Setuptools is installed by default. If you need pip and wheel, enable an appropriate supported repository such as EPEL or the PyPA Copr repository first, then install the packages:
Recommended Free Tools
sudo dnf install python3-pip python3-wheel
On an older release, use its supported repository and package-management instructions. Do not assume that running the install command before enabling the needed repository will work.
Install IDLE only if you want its GUI
If you specifically need IDLE, the Python Unix documentation gives this DNF command:
Rank #2
sudo dnf install python3-idle
Install Python 3 on Ubuntu
Install the default Python 3 package
Refresh APT’s package metadata before installing, then check the interpreter:
sudo apt update
sudo apt install python3
python3 --version
Ubuntu’s python3 package installs the distribution’s default Python 3. Ubuntu system tools use the system Python, and /usr/bin/python3 points to Ubuntu’s currently default Python version. Leave that operating-system-managed interpreter in place rather than swapping it for a manually installed version.
Quick wins for a faster PC:
Scan for outdated or missing drivers - takes under a minuteDriver Scan →Clear out junk files and repair common Windows errorsFree Scan →Install the standard development tools
For common project work, install the virtual-environment and package-installer modules:
sudo apt install python3-venv python3-pip
Ubuntu also provides python3-full, a meta-package that follows the currently default Python version and is a convenient choice for a more complete default runtime. Choose it if you want that broader set of standard components rather than adding only the tools you need.
Install Python 3 on Windows
Install the Python Install Manager
Windows does not include a system-supported Python installation. Install the current Python Install Manager from python.org/downloads or the Microsoft Store. After installation, the python, py, and pymanager commands should be available in Command Prompt or PowerShell.
The Install Manager can install and select runtimes. Use py list to see installed Python versions. The Windows guide’s PATH prompt is optional if you prefer to invoke Python through the py command. The older Python launcher documentation is deprecated in Python 3.14 in favor of the Install Manager.
Check the installation
Open a new Command Prompt or PowerShell window and run:
py --version
python --version
The first command uses the Python launcher interface. The second checks whether the python command resolves in that shell. If a command is not recognized, see the troubleshooting section below before reinstalling.
Verify Python and select the intended version
Run version checks in your operating-system terminal, not at the interactive Python prompt, which looks like >>>. On Linux, the standard check is:
python3 --version
On Windows, use:
py --version
If the version is not the one your project requires, find which executable or runtime is selected before changing anything. On Windows, use py list to inspect installed versions and the supported py -3.x selector where appropriate. On Linux, check the executable selected by your shell and the version provided by your configured OS repositories. A full executable path can remove ambiguity when several installations exist.
Outdated Drivers Are Slowing You Down
One free scan finds every outdated or missing driver and matches the right update for your exact hardware.Free scan · exact hardware matchPC Slower Than It Used to Be?
A free scan shows the junk files, broken settings and background clutter dragging Windows down - then fixes them in one click.Free scan · Windows 10 & 11Use a virtual environment for each project
A virtual environment gives a project its own package installation location. This keeps project dependency changes separate from the operating system’s Python and from other projects. Create it from the project’s directory.
Linux: CentOS and Ubuntu
On Ubuntu, first ensure python3-venv is installed. Then, on either Linux distribution, create and activate the environment:
python3 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
After activation, the prompt may show the environment name and python refers to its interpreter. Install project packages while the environment is active. To leave it, run deactivate.
Windows: PowerShell
From the project directory, create and activate the environment, then update pip inside it:
python -m venv .venv
..venvScriptsActivate.ps1
python -m pip install --upgrade pip
Run the activation command in PowerShell. Once active, install that project’s packages there. When finished, run deactivate. The environment’s activation changes apply to the current shell session.
Best Value
Use python versus python3 carefully
On Linux, python3 explicitly selects Python 3 and is the dependable system-level command for the procedures above. Ubuntu’s optional python-is-python3 package can provide a python symlink to Python 3, but scripts that need reproducibility should name their interpreter explicitly or run within an activated virtual environment.
On Windows, the Install Manager makes python and py available after installation. Prefer the launcher when you need to inspect or select among installed runtimes; use the project environment’s python after activation for project commands.
Troubleshoot installation and version problems
“Command not found” on Linux
- Confirm the package installation completed without an error and check the command appropriate to Linux:
python3 --version. - On an older CentOS release, check whether it uses YUM rather than DNF and whether the release’s repositories provide the package.
- If the interpreter exists but the shell cannot find it, inspect the executable path and the shell’s
PATHrather than installing a second copy immediately.
“Python” or “py” is not recognized on Windows
- Close and reopen Command Prompt or PowerShell after installing the manager, then retry
py --version. - Check whether the Python Install Manager is installed and inspect PATH and existing Python installations using the troubleshooting guidance in the official Windows guide.
- If you chose not to add the optional PATH entry, use
pyto invoke Python.
The version is older or different from what the project expects
On Linux, the package manager installs the release selected by your OS repositories. A newer upstream minor release may require another repository or a source build; the right option depends on the specific OS release and support requirements. On Windows, inspect available runtimes with py list and select the required version using the Install Manager’s supported selector. Avoid changing the system interpreter just to make one project use a different version.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
pip is missing or package installation affects the wrong Python
- On Ubuntu, install
python3-pipif you need the package tool, and create a virtual environment withpython3-venv. - On CentOS/RHEL, enable an appropriate supported repository for pip and wheel before installing them; the core repositories may not provide those packages.
- Use
python -m pipafter activating the project’s virtual environment. This binds pip to that environment’s interpreter instead of relying on an ambiguous standalonepipcommand.
Virtual-environment creation fails
On Ubuntu, check that python3-venv is installed. On any platform, run the creation command with the interpreter you intend to use and from a directory where you can write files. If more than one Python runtime is installed, verify its version first.
Or skip the browser setup
If you need a website screenshot from a script rather than a local browser installation, ScreenshotNeo accepts a URL in one GET request and returns a PNG, JPEG, WebP, or PDF. For example, using cURL:
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
See the ScreenshotNeo documentation for API details. It accepts cookie or consent banners and removes more than 60 known consent platforms, newsletter popups, and chat widgets before capture; each step can be turned off. Bot checks, blank pages, timeouts, failed loads, and cache hits cost nothing, and response headers report the page verdict and billing status. Its MCP server provides take_screenshot, get_page_info, and capture_pdf tools for Claude, Cursor, and other MCP clients. The Free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000 shots.
Sign up free for 1,000 screenshots a month, with no card required.
Free tools Windows power users keep installed
One-click scans. No signup required.
Frequently Asked Questions
Does installing Python 3 also install Python 2?
These procedures install or select Python 3. They do not require a Python 2 installation.
Can I install more than one Python version?
Yes. The Windows Install Manager can install and select runtimes; on Linux, available versions depend on the release and repositories. Keep project dependencies isolated in virtual environments.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

