Building means compiling the source code to binary in a sandbox location where it won't affect your system if something goes wrong, like a build subdirectory inside the source code directory.

Install means copying the built binaries from the build subdirectory to a place in your system path, where they become easily accessible. This is rarely done by a straight copy command, and it's often done by some package manager that can track the files created and easily uninstall them later.

Usually, a build command does all the compiling and linking needed, but Python is an interpreted language, so if there are only pure Python files in the library, there's no compiling step in the build. Indeed, everything is copied to a build directory, and then copied again to a final location. Only if the library depends on code written in other languages that needs to be compiled you'll have a compiling step.

Answer from Pedro Werneck on Stack Overflow
🌐
Python Developer's Guide
devguide.python.org › getting-started › setup-building
Setup and building - Python Developer's Guide
1 week ago - Once CPython is done building you will then have a working build that can be run in-place; ./python on most machines (and what is used in all examples), ./python.exe wherever a case-insensitive filesystem is used (for example, on macOS by default), in order to avoid conflicts with the Python directory.
🌐
PyPI
pypi.org › project › build
build · PyPI
A simple, correct Python build frontend.
Discussions

python - What is Building and Installing? - Stack Overflow
This is probably a question that has a very easy and straightforward answer, however, despite having a few years programming experience, for some reason I still don't quite get the exact concepts o... More on stackoverflow.com
🌐 stackoverflow.com
What Exactly Does a Build System in Python Do?
Building for deployment is one. This is a bit old apparently but explains a bit: https://setuptools.pypa.io/en/latest/userguide/index.html Its building binary wheels that can be hosted on PyPi or elsewhere and then installed using pip/uv/poetry. "PyPI primarily hosts Python packages in the form of source archives, called "sdists", or of "wheels" [8] that may contain binary modules from a compiled language." - https://en.wikipedia.org/wiki/Python_Package_Index More on reddit.com
🌐 r/learnpython
6
18
March 26, 2025
How Do I Actually Build Something With Python?
I think u/Meshi26 's advice is spot on. I struggled with the same thing while stuck in tutorial hell for programming. I decided that I was going to build my own digital assistant like Jarvis from the Iron Man movies and comics. Then I thought about all the hundreds of tasks that I would want and then kept breaking those tasks down. Then I started building real things. I have a small YouTube showing off some of the tasks that Python can do. https://www.youtube.com/channel/UCW34Ghe9-_TCA5Vy3-Agfnw More on reddit.com
🌐 r/learnpython
89
546
August 22, 2020
Post your Python builds here!
I've got the same build, working on engineering it out (so much mining left to do...) as my goto multipurpose. I'd love for it to be better at combat, but I think I'll simply have to stick to my Vulture for those goals. If we're going to need to relocate, I'll be investing in some lightweight mods. More on reddit.com
🌐 r/EliteDangerous
20
4
September 8, 2017
🌐
PyPI
pypi.org › project › python-build
python-build · PyPI
BuildPython is a python library to download and build a specified version of python into a specified directory.
      » pip install python-build
    
Published: Feb 09, 2016
Version: 0.2.13
🌐
Python Packaging
packaging.python.org › en › latest › guides › section-build-and-publish
Building and Publishing - Python Packaging User Guide
Toggle navigation of Building and Publishing · Writing your pyproject.toml · Packaging and distributing projects · Dropping support for older Python versions · Packaging binary extensions · Packaging namespace packages · Creating and packaging command-line tools ·
🌐
Readthedocs
python-build.readthedocs.io › en › stable
python-build — python-build 0.0.4 documentation
python-build will invoke the PEP 517 hooks to build a distribution package.
🌐
Medium
medium.com › @akashnagpal112 › best-python-build-tools-every-developer-should-know-in-2026-5460e70980cf
Best Python Build Tools Every Developer Should Know in 2026 | by Akash Nagpal | Medium
February 22, 2026 - Where it shines: Intuitive CLI, automatic virtual environments, .env file support. Where it struggles: Slower dependency resolution on large projects; limited to Python-only workflows. PyBuilder takes a declarative, plugin-based approach to build configuration.
Find elsewhere
🌐
GitHub
github.com › pypa › build
GitHub - pypa/build: A simple, correct Python build frontend · GitHub
If you are using cibuildwheel, build is integrated and the default builder in 3.0+. If you want to use uv as the installer, you can use: ... On conda-forge, this package is called python-build.
Author: pypa
🌐
Python Packaging
packaging.python.org › tutorials › packaging-projects
Packaging Python Projects - Python Packaging User Guide
Some build backends are part of larger tools that provide a command-line interface with additional features like project initialization and version management, as well as building, uploading, and installing packages.
🌐
Reddit
reddit.com › r/learnpython › what exactly does a build system in python do?
r/learnpython on Reddit: What Exactly Does a Build System in Python Do?
March 26, 2025 -

I consider myself a decent python developer. I have been working as a machine learning engineer for a few years, delivered a lot of ETL pipelines, MLOps projects (scaled out distributed model training and inference) using python and some cloud technologies.

My typical workflow has been to to expose rest APIs using combination of FastAPI, with celery backend for parallel task processing, deployment on Kubernetes etc. For environment management, I have used a combination of uv from Astral and Docker.

But now I am seeing a lot of posts on python build systems, such as hatchling but cannot figure out what is the value and what exactly do they do?

I have done some fair bit of C++ and Rust, and to me build refers to compilation. But Python does not compile, you run the source code directly, from the required entry point in a repository. So what exactly is it something like hatch or hatchling (is there a difference?) do that I cannot do with my package manager like uv?

In this regard, any link to a tutorial explaining the use case, and teaching the utility from ground up would be appreciated too.

Top answer
1 of 3
6
Building for deployment is one. This is a bit old apparently but explains a bit: https://setuptools.pypa.io/en/latest/userguide/index.html Its building binary wheels that can be hosted on PyPi or elsewhere and then installed using pip/uv/poetry. "PyPI primarily hosts Python packages in the form of source archives, called "sdists", or of "wheels" [8] that may contain binary modules from a compiled language." - https://en.wikipedia.org/wiki/Python_Package_Index
2 of 3
6
Its value is packaging a program or library for distribution. Then someone can just install it and have the dependencies resolved automatically. to me build refers to compilation Building means creating some sort of package that can be used. For compiled languages, that includes compiling the source code, but there's also assembly, as well as linking all of the compilation units together (or, I guess some subset, if e.g. you're creating multiple executables or something). There might also be things that don't involve normal compilation, such as creating doc files, graphics, etc. Building is not synonymous with compilation. But Python does not compile Not true. The Python interpreter compiles the source code to bytecode at runtime, as much as necessary. (I think source-based interpretation does exist, but having to constantly parse text on top of everything else is quite a performance drain.) In the case of modules, the compiled code is also cached and stored in .pyc files under __pycache__ directories, so a module doesn't have to be compiled every time, only if it is changed. Modules can also be pre-compiled, which a package manager like pip will do when installing them. It's not necessariy something the build system itself does, unlike with compiled languages.
🌐
Gregoryszorc
gregoryszorc.com › docs › python-build-standalone › main
Python Standalone Builds — python-build-standalone documentation
The Python distributions are built in a manner to minimize run-time dependencies. This includes limiting the CPU instructions that can be used and limiting the set of shared libraries required at run-time. The goal is for the produced distribution to work on any system for the targeted architecture. The builds incorporate compiler optimizations such as profile-guided optimization (PGO), link-time optimization (LTO), and, where appropriate, BOLT post-link binary optimization.
🌐
GitHub
github.com › pyenv › pyenv › blob › master › plugins › python-build › README.md
pyenv/plugins/python-build/README.md at master · pyenv/pyenv
Run the python-build command with the exact name of the version you want to install and the full path where you want to install it. For example, ... To see a list of all available Python versions, run python-build --definitions.
Author: pyenv
🌐
Tonsky
tonsky.me › blog › python-build
Python as a build tool @ tonsky.me
September 23, 2021 - Normally, when starting a Java project (or any other programming project, really), you don’t want to reinvent the wheel. You go with the de-facto build system, folder structure, environment, etc. The ones that the rest of the world is using. Yet, both Skija and JWM are built using Python scripts instead of more traditional Ant/Maven/Gradle/SBT.
🌐
Build-python-from-source
build-python-from-source.com
Build Python from Source | Bash Script Generator for Linux
Generate copy & paste bash scripts to compile and install any Python version from source on major Linux distributions. Configure build options like PGO, LTO, free-threading, JIT and more.
🌐
GitHub
github.com › rstudio › python-builds
GitHub - rstudio/python-builds: an opinionated environment for compiling python · GitHub
Posit no longer builds its own Python binaries. Previous Posit-built versions will remain available, but new patch versions for Python 3.9 - 3.13 will not be built.
Starred by 9 users
Forked by 2 users
Languages: Shell 73.0% | Python 19.1% | Makefile 5.7% | Dockerfile 2.2%
🌐
PyDevTools
pydevtools.com › home › python developer tooling handbook › reference › build
build: Python Package Build Frontend | pydevtools
September 7, 2026 - build is PyPA's PEP 517-compliant frontend tool for building Python packages using any standards-compliant build backend.
🌐
Python
docs.python.org › 2.0 › inst › how-build-works.html
2.3 How building works
By default, this is build under the distribution root; if you're excessively concerned with speed, or want to keep the source tree pristine, you can change the build directory with the --build-base option. For example: python setup.py build --build-base=/tmp/pybuild/foo-1.0 (Or you could do this permanently with a directive in your system or personal Distutils configuration file; see section
🌐
Reddit
reddit.com › r/learnpython › how do i actually build something with python?
r/learnpython on Reddit: How Do I Actually Build Something With Python?
August 22, 2020 -

I've been programming in Python for a while now. I'm familiar with all the basic functionalities and have been working on algorithms for a while as well. My question is, how do I actually build something solid with Python (say, an application, or a program that automatically replies to all my emails with a pre-written message)? I simply have no clue how to do that. I'm only familiar with the "logic" of Python, but I can't "build" anything with it. Where do I start? What do I learn?

🌐
Medium
medium.com › @ebimsv › building-python-packages-07fbfbb959a9
Building Python Packages. A Comprehensive Guide to setup.py and… | by Ebrahim Mousavi | Medium
October 13, 2024 - In Python, there are two common approaches to creating packages that can be installed with pip: using setup.py and using pyproject.toml Here’s a brief description of each: