D2
D2 is a modern diagram scripting language that turns text to diagrams. observed · 2026-10-11
Health v2 · maintenance only
92/100
- Activity 97
- Release rhythm 82
- Longevity 100
How is this computed?
round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-10-21. Adoption (stars, forks) is never an input.
- gap_med: 89
- age_days: 1506
- days_rel: 43
- days_push: 18
- n_releases_24m: 6
Adoption not part of the score
25596 stars · 763 forks observed · 2026-10-11
What it is AI-extracted, prompt v1, taxonomy v1, 2026-10-12, confidence 0.98
D2 is a modern declarative diagram scripting language that converts plain‑text definitions into visual diagrams. It provides a fast CLI, a Go library, and an npm package for generating SVG, PNG, and animated diagrams.
Use cases
- Create architecture diagrams from simple text files
- Generate flowcharts and network diagrams programmatically
- Render SVG diagrams for inclusion in markdown documentation
- Produce animated diagrams for presentations
- Automate diagram generation in CI/CD pipelines
- Embed system component visualizations directly in code repositories
When to choose
- You need a lightweight, scriptable way to produce diagrams without a GUI
- You prefer a declarative text format that can be version‑controlled
- You want to integrate diagram generation into build scripts or CI pipelines
- You require fast rendering with support for themes and multiple output formats
When to avoid
- You need an interactive drag‑and‑drop diagram editor
- Your diagrams require complex 3D or real‑time simulation capabilities
- You only want a WYSIWYG tool with no scripting support
Facets
cli-tool · maturity active
parser static-site-generator cli documentation developer-tools windows go cross-platform diagramming text-to-diagram d2lang svg-export theme-support linux macos nodejs
3 sources
- readme: https://github.com/d2lang/d2 · fetched 2026-10-11 · 6849eacdfce9
- homepage: https://d2lang.com · fetched 2026-09-28 · 928c287af150
- site_page: https://d2lang.com/releases/intro · fetched 2026-09-28 · 967eac1b4fc4
Member repositories
| Repository | Role | Health v2 |
|---|---|---|
| d2lang/d2 | main | 92 |
| d2lang/d2-vscode | plugin | 71 |
| d2lang/d2-obsidian | plugin | 62 |
| d2lang/d2-docs | docs | 76 |
| d2lang/d2-vim | plugin | 71 |
| d2lang/d2-playground | frontend | 76 |
For agents
Data as of 2026-10-19T08:05:51.212177+00:00 · Report a problem