Skip to content

Introduction

stagelint runs commands such as linters, formatters and type checkers on the files you are about to commit, and stages what they fix. It runs from its own pre-commit hook, from your hook manager, from a coding agent's hooks, or in CI.

A pre-commit run: independent globs in parallel, overlapping ones in order

Features

  • Partially staged files are three-way merged, so a conflict with your unstaged changes never blocks the commit.
  • Runs 5 to 30 times faster than other pre-commit tools.
  • A single binary with no runtime, installed through the package manager you already use.
  • Prefers tools installed in your project over global ones, so there is no need for npx or uv run.
  • Supports monorepos with nested config files.
  • Plugs into coding agents such as Claude Code, Codex and Cursor, so they fix failing checks before handing work back to you.
  • Runs in CI, checking only the files a pull request or push changed.

Where to start