Published on Wednesday, May 7, 2025
🚀 Meet uv: The Next-Gen Python Package Manager Built for Speed
Posted by

🔍 Introduction
Python’s packaging tools have come a long way—from pip to poetry. But as projects grow in size and complexity, many of these tools start to slow down or become harder to manage.
Meet uv — a blazing-fast, Rust-powered package and project manager for Python. Designed to be a drop-in replacement for existing tools, uv dramatically improves performance and simplifies your development workflow.
✨ Key Features
- 🧩 Drop-in Replacement: Use familiar commands like
uv pip install. - ⚡ Lightning Fast: Benchmarks show 80–115x speed improvements with a warm cache.
- 🧠 Smarter Dependency Management: Detects and resolves conflicts with clear error messaging.
- 💾 Disk-Efficient: Uses a global cache to deduplicate dependencies.
- 🛠️ Script Runner: Inline dependency execution via uv run.
- 🗂️ Universal Lockfile: Portable and consistent lockfiles.
- 🏗️ Workspace Support: Cargo-style multi-project management.
- 📦 Advanced Support: Git dependencies, local installs, editable mode, and more.
🔧 Installation
Using the Official Installer
macOS / Linux
curl -LsSf https://astral.sh/uv/install.sh | sh
Windows (PowerShell)
irm https://astral.sh/uv/install.ps1 | iex
Using pip or pipx
pip install uv
# or
pipx install uv
Note:
After installation, add ~/.local/bin to your system PATH if needed.
🛠️ Creating a New Project
Option 1: In One Command
uv init hello-world
cd hello-world
Option 2: In an Existing Directory
mkdir hello-world
cd hello-world
uv init
📦 Managing Dependencies
➕ Add a Dependency
uv add flask
Remove a Dependency
uv remove flask
🚀 Running Scripts
Run a script
uv run main.py
def main():
print("Hello from hello-world!")
if __name__ == "__main__":
main()
Run with one inline dependency
uv run --with requests main.py
import requests
print(requests.get("https://api.github.com").json())
Run with multiple dependencies
uv run --with requests --with beautifulsoup4 main.py
import requests
from bs4 import BeautifulSoup
res = requests.get("https://example.com")
soup = BeautifulSoup(res.text, "html.parser")
print(soup.title.text)
🐍 Managing Python Versions
uv can detect and use your system Python. But it also installs and manages Python versions automatically, so you don’t need to install Python separately.
📥 Install a Specific Python Version
uv python install 3.12
🧩 Install Multiple Versions
uv python install 3.11 3.12
♻️ Reinstall Python Versions
uv python install --reinstall
Note:
Reinstalling may resolve issues even if the version hasn’t changed.
📋 View Installed Versions
uv python list
See the python list documentation for more details.
🧾 Conclusion
uv isn’t just another package manager—it’s a modern toolchain built for speed, clarity, and scalability. Whether you’re managing dependencies, running scripts, or juggling multiple Python versions, uv helps you move faster and stay organized.