Install guide
You can install all the Modular APIs and tools (including MAX and Mojo) as a
single package called modular
, using any Python or Conda package manager. On
this page, we show how to install using pip
, uv
, conda
, and pixi
.
The modular
package is available as a nightly and a stable build. You can
also select the latest nightly or stable documentation, using a drop-down in
the website header. By default, we show the nightly version so you always see
the latest APIs and documentation.
If you just want to get started, instead see our quickstart guide.
Install
To get the latest performance improvements and new features, we recommend installing our nightly build, which we release several times a week. If you want a better tested but slightly older version, you can install a stable build. (Each stable release is described in the changelog.)
- pip
- uv
- conda
- pixi
- Create a project folder:
mkdir example-project && cd example-project
mkdir example-project && cd example-project
- Create and activate a virtual environment:
python3 -m venv .venv/example-project \
&& source .venv/example-project/bin/activatepython3 -m venv .venv/example-project \
&& source .venv/example-project/bin/activate - Install the
modular
Python package:- Nightly
- Stable
pip install modular \
--extra-index-url https://download.pytorch.org/whl/cpu \
--extra-index-url https://dl.modular.com/public/nightly/python/simple/pip install modular \
--extra-index-url https://download.pytorch.org/whl/cpu \
--extra-index-url https://dl.modular.com/public/nightly/python/simple/pip install modular \
--extra-index-url https://download.pytorch.org/whl/cpu \
--extra-index-url https://modular.gateway.scarf.sh/simple/pip install modular \
--extra-index-url https://download.pytorch.org/whl/cpu \
--extra-index-url https://modular.gateway.scarf.sh/simple/
- If you don't have it, install
uv
:curl -LsSf https://astral.sh/uv/install.sh | sh
curl -LsSf https://astral.sh/uv/install.sh | sh
Then restart your terminal to make
uv
accessible. - Create a project:
uv init example-project && cd example-project
uv init example-project && cd example-project
- Create and start a virtual environment:
uv venv && source .venv/bin/activate
uv venv && source .venv/bin/activate
- Install the
modular
Python package:- Nightly
- Stable
uv pip install modular \
--extra-index-url https://download.pytorch.org/whl/cpu \
--extra-index-url https://dl.modular.com/public/nightly/python/simple/ \
--index-strategy unsafe-best-matchuv pip install modular \
--extra-index-url https://download.pytorch.org/whl/cpu \
--extra-index-url https://dl.modular.com/public/nightly/python/simple/ \
--index-strategy unsafe-best-matchuv pip install modular \
--extra-index-url https://download.pytorch.org/whl/cpu \
--extra-index-url https://modular.gateway.scarf.sh/simple/ \
--index-strategy unsafe-best-matchuv pip install modular \
--extra-index-url https://download.pytorch.org/whl/cpu \
--extra-index-url https://modular.gateway.scarf.sh/simple/ \
--index-strategy unsafe-best-match
- If you don't have it, install conda. A common choice is with
brew
:brew install miniconda
brew install miniconda
- Initialize
conda
for shell interaction:conda init
conda init
If you're on a Mac, instead use:
conda init zsh
conda init zsh
Then restart your terminal for the changes to take effect.
- Create a project:
conda create -n example-project
conda create -n example-project
- Start the virtual environment:
conda activate example-project
conda activate example-project
- Install the
modular
conda package:- Nightly
- Stable
conda install -c conda-forge -c https://conda.modular.com/max-nightly/ modular
conda install -c conda-forge -c https://conda.modular.com/max-nightly/ modular
conda install -c conda-forge -c https://conda.modular.com/max/ modular
conda install -c conda-forge -c https://conda.modular.com/max/ modular
- If you don't have it, install
pixi
:curl -fsSL https://pixi.sh/install.sh | sh
curl -fsSL https://pixi.sh/install.sh | sh
Then restart your terminal for the changes to take effect.
- Create a project:
pixi init example-project \
-c https://conda.modular.com/max-nightly/ -c conda-forge \
&& cd example-projectpixi init example-project \
-c https://conda.modular.com/max-nightly/ -c conda-forge \
&& cd example-project - Install the
modular
conda package:- Nightly
- Stable
pixi add modular
pixi add modular
pixi add "modular==25.3"
pixi add "modular==25.3"
- Start the virtual environment:
pixi shell
pixi shell
The modular
package installs MAX, Mojo, and other package dependencies.
Uninstall
- pip
- uv
- conda
- pixi
You can uninstall modular
from your virtual environment with the following
command:
pip uninstall modular
pip uninstall modular
To deactivate your virtual environment, run:
deactivate
deactivate
You can uninstall modular
from your virtual environment with the following
command:
uv pip uninstall modular
uv pip uninstall modular
To deactivate your virtual environment, run:
deactivate
deactivate
You can uninstall modular
from your virtual environment with this
command:
conda remove modular
conda remove modular
To deactivate your virtual environment, run:
deactivate
deactivate
You can uninstall modular
from your virtual environment with this
command:
pixi remove modular
pixi remove modular
To deactivate your virtual environment, run:
exit
exit
What's included
- pip/uv
- conda/pixi
The modular
Python wheel installs the following:
- MAX tools and libraries
- Mojo tools and libraries
mojo
CLI- Mojo standard library
- Mojo LSP
pip
known issues:
- The Mojo debugger isn't included. If you want to develop
with Mojo, we currently recommend you install the
modular
conda package withpixi
orconda
.
The max
conda package installs the following:
- MAX tools and libraries
- Mojo tools and libraries
mojo
CLI- Mojo standard library
- Mojo LSP
- Mojo debugger
The modular
package installs the max
CLI.
pixi
known issues:
- You might encounter issues if you invoke
pixi
within aconda
virtual environment. It's best if you don't mix the two tools.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!