> ## Documentation Index
> Fetch the complete documentation index at: https://b01t.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Install b01t: Python Quantum Safety Library

> Install b01t in your Python environment using pip or uv. Requires Python 3.11 or later and qiskit 1.0 or later for circuit compilation.

b01t is a pure-Python package that you install from PyPI. It requires Python 3.11 or later and pulls in Qiskit as its only runtime dependency — Qiskit is the compilation target that turns your certified `ExactProgram` into a runnable `QuantumCircuit`.

## Requirements

Before you install, check that your environment meets the minimum versions:

* **Python 3.11 or later** — b01t uses modern Python features including structural pattern matching and precise union types that are not available in earlier versions
* **qiskit 1.0 or later** — required for the `QiskitBackend` that compiles b01t IR to `QuantumCircuit` objects

<Note>
  If you are using a virtual environment manager (recommended), create and activate your environment before running the install command.
</Note>

## Install b01t

<CodeGroup>
  ```bash pip theme={null}
  pip install b01t-lang
  ```

  ```bash uv theme={null}
  uv add b01t
  ```
</CodeGroup>

Both commands install b01t and its `qiskit` dependency automatically. There is no separate step to install Qiskit.

## Verify the installation

After installing, confirm that b01t imported correctly and that the version is available:

```python theme={null}
import b01t
from b01t import coherent, QReg, Certification
from b01t.kit import ancilla, compute, phase, uncompute
from b01t import QiskitBackend, lower_exact_program

print("b01t imported successfully")
```

If this runs without errors, your installation is working.

<Tip>
  If you are using `uv`, you can also run the b01t command-line interface directly with `uv run b01t` without activating the virtual environment first.
</Tip>

## Qiskit and the backend

b01t uses Qiskit only for the final compilation step. Your programs are built and certified entirely within b01t — Qiskit is only needed when you call `QiskitBackend().emit(ir)` to produce a `QuantumCircuit`. If you are only using b01t's certification features and not compiling to Qiskit circuits, the dependency is still present but not invoked.

<Warning>
  Qiskit 1.0 introduced breaking changes from 0.x. If you have an existing environment with an older version of Qiskit, b01t's backend may not work correctly. Upgrade with `pip install --upgrade qiskit` or `uv add "qiskit>=1.0"`.
</Warning>
