Installation
Prerequisites
Python version
Flet requires Python 3.10 or later. (1)
- Check your Python version using
python --version.
Operating System
macOS
Flet supports macOS 12 (Monterey) or later.
Windows
Flet supports 64-bit version of Microsoft Windows 10 and Windows 11.
Linux
Flet supports Debian 10, 11 and 12 and Ubuntu 20.04, 22.04 and 24.04 LTS.
Desktop flavor (audio & video support)
On Linux, the Flet desktop client is available in two flavors: full and light.
The light flavor (default on Linux) does not include audio and video extensions, resulting in a smaller download. The full flavor bundles audio and video support out of the box.
To select the flavor, either set the FLET_DESKTOP_FLAVOR environment variable:
export FLET_DESKTOP_FLAVOR=full
or add the setting to your project's pyproject.toml:
[tool.flet]
desktop_flavor = "full"
If you use the light flavor and need audio or video, you will need to install the required libraries yourself — see the Audio and Video setup guides.
Windows Subsystem for Linux (WSL)
Flet apps can be run on WSL 2 (Windows Subsystem for Linux 2).
However, if you are getting cannot open display error follow this
guide for troubleshooting.
Creating a virtual environment (venv)
We recommend using a virtual environment for your Flet projects to keep dependencies isolated and avoid conflicts with your other Python projects.
First, create a new directory for your Flet project and switch into it:
mkdir my-app
cd my-app
Next, create and activate a virtual environment (we recommend using uv as package manager):
- uv
- pip
uv is "An extremely fast Python package and project manager, written in Rust".
Install uv if you haven't already, then run the following commands:
uv init --python='>=3.10'
uv venv
source .venv/bin/activate
Using Python's built-in venv module:
python -m venv .venv
source .venv/bin/activate
Install Flet
To install Flet and add it to your project dependencies, do the following depending on your package manager:
- uv
- pip
uv add 'flet[all]'
pip install 'flet[all]'
Verify installation
To make sure Flet has been installed correctly, we can check its version using the --version (or -V) flag or the doctor command:
- uv
- pip
uv run flet --version
# or
uv run flet doctor
flet --version
# or
flet doctor
Now you are ready to create your first Flet app.
Upgrade Flet
To upgrade Flet to its latest version:
- uv
- pip
uv add 'flet[all]' --upgrade
pip install 'flet[all]' --upgrade