d2lang/d2
D2 is a modern diagram scripting language that turns text to diagrams.
Build with Backblaze B2
SDKs, agent skills, IDE extensions, and reference pipelines from Backblaze Labs. All open source.
Loading star history...
Where it stands
Rank, growth pace and release cadence relative to everything GStars tracks.
2 releases in the last 90 days, the latest 62 days ago, with 66 contributors on GitHub.
Peaked at #56 in the weekly ranking the week of Oct 19, its best in the past year.
Use Cases & Benefits
- Transforms textual scripts into visual diagrams using a modern, extensible diagram scripting language.
- Enables fast, customizable diagram generation with multiple layout engines and export formats, supporting live reload and rich language tooling.
- Use for creating software architecture diagrams programmatically with Go integration and plugin-based layout engines.
- Use for embedding diagram generation in documentation workflows via VSCode, Vim, Obsidian, and Markdown plugins.
- Use for visualizing database schemas, network topologies, or system workflows with text-to-diagram conversion and theme customization.
Should you depend on it?
License terms, project hygiene and risks, from GitHub metadata and GStars' snapshots.
License
Mozilla Public License 2.0
Weak copyleft: changes to the licensed code itself must be shared when you distribute it, but code that merely uses it can stay under your own license.
Community files
- README: present
- Contributing guide: present
- Code of conduct: present
Watch-outs
No watch-outs from GStars' checks.
General guidance from repository metadata, not legal advice. How we score
From the README
For more examples, see ./docs/examples.
The most convenient way to use D2 is to just run it as a CLI executable to produce SVGs from
.d2files.A browser window will open with
out.svgand live-reload on changes toin.d2.The easiest way to install is with our install script:
You can run the install script with
--dry-runto see the commands that will be used to install without executing them.Or if you have Go installed you can install from source though you won't get the manpage:
You can also install a release from source which will include manpages. See ./docs/INSTALL.md#source-release.
For detailed installation docs, see ./docs/INSTALL.md. We demonstrate alternative methods and examples for each OS.
As well, the functioning of the install script is described in detail to alleviate any concern of its use. We recommend using your OS's package manager directly instead for improved security but the install script is by no means insecure.
Daily snapshots
Stars gained per day, and how forks and open issues moved, from GStars' daily snapshots
Forks
777+58
Open issues
543-1
Compared with peers in Developer Tools
Fastest-growing repositories GStars tracks in this cohort for the week of Nov 8, by 7-day star growth
| Repository | Stars | +7d | Health | Last release |
|---|---|---|---|---|
| stablyai/orca | 121.4K | +6.7K | 75 | today |
| DietrichGebert/ponytail | 188.4K | +4.4K | 75 | 12 days ago |
| affaan-m/ECC | 300.8K | +4.3K | 75 | 40 days ago |
| herdrdev/herdr | 50.0K | +2.1K | 75 | 27 days ago |
| max-sixty/worktrunk | 12.4K | +1.9K | 75 | 21 days ago |
| d2lang/d2 | 25.8K | — | 62 | 62 days ago |
| Category median | 121.4K | +4.3K | 75 | — |
Discover Repositories
Search across tracked repositories by name or description