September 14, 2025

By Dante

Python Setup: How to install python

This guide shows you how to install Python 3.13 on Mac, Windows, and/or Linux.

Click a platform above to jump to its section.

Mac

Homebrew is the best way to install Python on Mac.

Check for Homebrew

Run the following command to check if Homebrew is already installed:

brew --version

If you see a version number, you can skip to Step 5. Otherwise, proceed to the next step.

Install Homebrew

Run the following installation script from brew.sh.

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

You may be prompted for your macOS password.

Add Homebrew to Your PATH

After installation, watch for this warning:

Warning: /opt/homebrew/bin is not in your PATH.
Instructions on how to configure your shell for Homebrew
can be found in the 'Next steps' section below.

If you see that message, run the following to configure your shell:

echo 'eval $(/opt/homebrew/bin/brew shellenv)' >> ~/.zprofile
eval $(/opt/homebrew/bin/brew shellenv)

This ensures the brew command will work the next time you open your terminal.

Confirm Homebrew Installation

Restart your terminal and run:

brew --version

You should see a version number confirming it's correctly installed.

Install Python 3.13

Now install Python with:

brew install python@3.13

If the output mentions conflicting files or says it can't link python@3.13, run:

brew link --overwrite python@3.13

Confirm Python Version

Verify the installation with:

python3.13 --version

You should see Python 3.13.x.

Now that Python 3.13 is installed, you're ready to install aegis.

Windows

You can install Python on Windows using the official installer from python.org

Check Your Windows System Type

Before downloading Python, make sure you know whether your system is 64-bit, 32-bit, or ARM64.

If you're unsure, follow these steps to find out:

Windows Search

Windows Search Result

Windows Sytem Type

Download the Installer

Go to python.org and scroll down to the Files section.

Choose the installer that matches your system type:

  • Windows installer (64-bit) — most common
  • Windows installer (32-bit)
  • Windows installer (ARM64)

Run the Installer

  1. Open the downloaded installer.
  2. Check the box that says "Add Python to PATH" at the bottom.
  3. Click Install Now.

Windows PATH

If you forget to check the PATH box, Python won't work in the terminal until you fix your environment variables.

Confirm the Installation

Open Command Prompt and run:

python --version

You should see Python 3.13.x.

If not, try:

py -3.13 --version

Still not working? Try restarting your PC and running the command again.

Now that Python 3.13 is installed, you're ready to install aegis.

Linux

You can install Python 3.13 on Linux using a package manager or by building from source, depending on your distro.

Check Your Distro

Make sure you know which Linux distribution you're using (e.g., Ubuntu, Fedora, Arch).

You can usually check with:

cat /etc/os-release

This tells you the distribution name and version.

Option 1: Ubuntu / Debian

Ubuntu 24.04+ might already have Python 3.13. To install manually:

sudo add-apt-repository ppa:deadsnakes/ppa
sudo apt update
sudo apt install python3.13

Confirm with:

python3.13 --version

You should see Python 3.13.x.

Option 2: Arch Linux

Arch users can install it directly from the AUR:

sudo pacman -Sy python313

This usually installs the latest version. Confirm with:

python3.13 --version

You should see Python 3.13.x.

Option 3: Build from Source (Works on Any Distro)

If your package manager doesn't offer Python 3.13, you can build it from source.

Install Build Dependencies

Make sure you install the required development tools and libraries. The package names vary slightly by distro, but here's a common example for Debian-based systems:

sudo apt update
sudo apt install -y \
  build-essential zlib1g-dev libncurses-dev libbz2-dev libreadline-dev \
  libsqlite3-dev libssl-dev libffi-dev liblzma-dev uuid-dev \
  wget curl llvm tk-dev libncursesw5-dev xz-utils

Just make sure you download the equivalent dev libraries on your distro.

Download and Extract the Source Code

cd /tmp
wget https://www.python.org/ftp/python/3.13.7/Python-3.13.7.tgz
tar -xvf Python-3.13.7.tgz
cd Python-3.13.7

Build and Install

./configure --enable-optimizations
make -j$(nproc)
sudo make altinstall

Install Command

Don't use make install -- make altinstall avoids overwriting the system’s default python3.

Verify the Installation

Restart your terminal and run:

python3.13 --version

You should see Python 3.13.x.

Cleanup

Once Python is installed, you can safely remove the temporary build files:

rm -rf /tmp/Python-3.13.7 /tmp/Python-3.13.7.tgz

Now that Python 3.13 is installed, you're ready to install aegis.