Skip to content

Installation

Install kfactory

pip install kfactory

Or with uv (recommended):

uv add kfactory

Optional extras

Extra What it adds
kfactory[git] Git-based layout diffing (difftest)
kfactory[ipy] Jupyter / IPython display helpers (cell.plot())
kfactory[dev] Development tools (pytest, ruff, mypy, …)

Install multiple extras at once:

pip install "kfactory[git,ipy]"

Verify the installation

import kfactory as kf

print(kf.__version__)

# Create a simple cell to confirm everything works
c = kf.KCell(name="hello")
c.shapes(kf.kcl.layer(1, 0)).insert(kf.kdb.Box(0, 0, 5000, 2000))
print("KCell created:", c.name)

If no errors appear, kfactory is installed correctly.

Next steps