CLI

quarto-graph installs three commands: prerender and postrender, which a project’s own _quarto.yml wires up as its pre-render/post-render steps, and check, for editor and CI tooling that needs to know about unresolved wikilinks without running a full Quarto render.

quarto-graph prerender / quarto-graph postrender

project:
  type: website
  pre-render: quarto-graph prerender
  post-render: quarto-graph postrender

prerender builds the wikilink/alias registry and backlink map across every page in the project, before any single page renders. postrender assembles graph.json from that registry and each page’s own real rendered output path. Both run with the working directory already set to the project root (Quarto’s own guarantee for pre-render/post-render commands), so neither takes a path argument.

quarto-graph check

quarto-graph check <project_dir>

Read-only: scans every page under project_dir for [[wikilinks]] that don’t resolve, and prints a JSON array to stdout, one object per unresolved link, in scan order:

[
  {"file": "wikilinks-and-aliases/index.qmd", "line": 96, "col": 44, "target": "This Page Does Not Exist Anywhere", "text": "This Page Does Not Exist Anywhere"}
]

No files are written, and no other side effects happen. This is why it’s separate from quarto render’s own pre-render/render/post-render passes: an editor or CI job can call check at any time, without triggering quarto render or a full Python/Lua pass.

Page discovery is the same logic the pre-render pass uses: quarto inspect when project_dir has a _quarto.yml/_quarto.yaml, falling back to a plain recursive .qmd/.md walk for a bare folder of notes with no Quarto project file.

check vs. --strict

Both surface the same unresolved-link data, but at different times and for different consumers:

quarto-graph check --strict
When it runs On demand, any time During quarto render
What it does Prints JSON, exits normally Fails the build
Who calls it An editor, a CI lint step quarto render itself

Enabling --strict

Since pre-render is a plain quarto-graph prerender command, --strict is just an extra argument:

project:
  pre-render: quarto-graph prerender --strict

Backlinks