Python environments
Three ways to keep the Python install isolated. A plain pip install open-webui is on the Quick Start; this page covers uv, Conda and venv, and how to uninstall any of them.
Open WebUI supports Python 3.11 and 3.12. Python 3.13 is not supported yet: a handful of our dependencies still need to ship 3.13-compatible releases, and until they do, installs on 3.13 will fail or break at runtime.
- For production, run the Docker image or use the latest Python 3.11. This is the combination we test against most heavily.
- Python 3.12 also works, but we have seen very rare reports of odd behaviour on 3.12 that we have not reproduced on 3.11. If something inexplicable happens on 3.12, drop to the latest 3.11 first.
Installation with uv
The uv runtime manager ensures seamless Python environment management for applications like Open WebUI. Follow these steps to get started:
1. Install uv
Pick the appropriate installation command for your operating system:
-
macOS/Linux:
curl -LsSf https://astral.sh/uv/install.sh | sh -
Windows:
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
2. Run Open WebUI
Once uv is installed, running Open WebUI is a breeze. Use the command below, ensuring to set the DATA_DIR environment variable to avoid data loss. Example paths are provided for each platform:
-
macOS/Linux:
DATA_DIR=~/.open-webui uvx --python 3.11 open-webui@latest serve -
Windows (PowerShell):
$env:DATA_DIR="C:\open-webui\data"; uvx --python 3.11 open-webui@latest serve
Open WebUI is now running at http://localhost:8080.
Setting DATA_DIR ensures your chats and settings are saved in a predictable location. If you don't set it, uvx might store it in a temporary folder that gets deleted when the process ends.
Uninstall
To remove Open WebUI when running with uvx:
-
Stop the Server: Press
Ctrl+Cin the terminal where it's running. -
Uninstall from UV: Enter
uv tool uninstall open-webui -
Available cleanup commands: The
uvxcommand runs the application ephemerally or from cache. To remove cached components:uv cache clean -
Remove Data (WARNING: Deletes all data): Delete your data directory (default is
~/.open-webuior the path set inDATA_DIR):rm -rf ~/.open-webui
Install with Conda
-
Create a Conda Environment:
conda create -n open-webui python=3.11 -
Activate the Environment:
conda activate open-webui -
Install Open WebUI:
pip install open-webui -
Start the Server:
open-webui serve
If your terminal says the command doesn't exist:
- Ensure your conda environment is activated (
conda activate open-webui). - If you want to store your data in a specific place, use (Linux/Mac):
DATA_DIR=./data open-webui serveor (Windows):$env:DATA_DIR=".\data"; open-webui serve
Uninstall
-
Remove the Conda Environment:
conda remove --name open-webui --all -
Remove Data (WARNING: Deletes all data): Delete your data directory (usually
~/.open-webuiunless configured otherwise):rm -rf ~/.open-webui
Using Virtual Environments
Create isolated Python environments using venv.
Venv Steps
-
Create a Virtual Environment:
python3 -m venv venv -
Activate the Virtual Environment:
-
On Linux/macOS:
source venv/bin/activate -
On Windows:
venv\Scripts\activate
-
-
Install Open WebUI:
pip install open-webui -
Start the Server:
open-webui serve
If your terminal says the command doesn't exist:
- Ensure your virtual environment is activated (Step 2).
- If you want to store your data in a specific place, use:
DATA_DIR=./data open-webui serve
Uninstall
-
Delete the Virtual Environment: Simply remove the
venvfolder:rm -rf venv -
Remove Data (WARNING: Deletes all data): Delete your data directory (usually
~/.open-webuiunless configured otherwise):rm -rf ~/.open-webui
Uninstall a plain pip install
-
Uninstall the package:
pip uninstall open-webui -
Remove data (optional, deletes all data):
rm -rf ~/.open-webui