DEV Community

Kenechukwu Anoliefo
Kenechukwu Anoliefo

Posted on

⚡ How I Installed UV for Python — My Quick Setup Guide

Recently, I discovered UV, a new tool for managing Python environments and dependencies — and honestly, it’s one of the fastest and cleanest tools I’ve tried so far.

If you’ve worked with Python long enough, you’ve probably used pip, venv, or even pip-tools. They work fine, but UV takes things to another level — it’s super fast, lightweight, and built by the same team that created Ruff, the blazing-fast Python linter.

Here’s how I got it installed and running 👇


💡 What is UV?

UV is like a next-generation pip and venv combined — it helps you create virtual environments, install packages, and manage dependencies seamlessly. The best part? It’s built in Rust, which makes it extremely fast and efficient.

It’s perfect if you:

  • Work on multiple Python projects
  • Hate waiting for packages to install 😅
  • Want consistent, reproducible environments

🛠 Step 1: Installing UV

To install UV, I opened my terminal and ran this command:

For macOS / Linux

curl -LsSf https://astral.sh/uv/install.sh | sh
Enter fullscreen mode Exit fullscreen mode

For Windows (PowerShell)

irm https://astral.sh/uv/install.ps1 | iex
Enter fullscreen mode Exit fullscreen mode

Installation took just a few seconds — no complications, no heavy dependencies.


🧰 Step 2: Verifying the Installation

After the setup, I confirmed everything was fine by running:

uv --version
Enter fullscreen mode Exit fullscreen mode

It returned the version number, which means it was ready to go! ✅


🧩 Step 3: Creating a Virtual Environment

I then created a virtual environment using UV (similar to python -m venv but faster):

uv venv myenv
Enter fullscreen mode Exit fullscreen mode

Then activated it with:

source myenv/bin/activate
Enter fullscreen mode Exit fullscreen mode

(or myenv\Scripts\activate on Windows)


🚀 Step 4: Installing Packages

This is where UV really shines — package installation is lightning fast!

For example:

uv pip install pandas scikit-learn
Enter fullscreen mode Exit fullscreen mode

It was done almost instantly.


📦 Step 5: Exporting Dependencies

To save my environment setup for later, I exported dependencies using:

uv pip freeze > requirements.txt
Enter fullscreen mode Exit fullscreen mode

And I can always reinstall them with:

uv pip install -r requirements.txt
Enter fullscreen mode Exit fullscreen mode

⚙️ Why I Love UV

✅ It’s fast — like, seriously fast.
✅ It simplifies environment and dependency management.
✅ It works across systems — Linux, macOS, and Windows.
✅ It’s easy to learn — minimal commands, clean output.


🧠 Final Thoughts

Installing UV was smooth and refreshing. I love tools that make my workflow faster and cleaner, and UV does exactly that.

If you’re a Python developer who’s tired of slow installs or environment chaos, I definitely recommend giving UV a try. ⚡🐍

Top comments (0)