Search...Search plugins and themes...
⌘K
Sign in
  • Get started
  • Download
  • Pricing
  • Enterprise
  • Account
  • Obsidian
  • Overview
  • Sync
  • Publish
  • Canvas
  • Mobile
  • Web Clipper
  • CLI
  • Learn
  • Help
  • Developers
  • Changelog
  • About
  • Roadmap
  • Blog
  • Resources
  • System status
  • License overview
  • Terms of service
  • Privacy policy
  • Security
  • Community
  • Plugins
  • Join the community
  • Discord
  • Forum / 中文论坛
  • Merch store
  • Brand guidelines
Follow us
DiscordTwitterBlueskyThreadsMastodonYouTubeGitHub
© 2026 Obsidian

Kroki

gregzurogregzuro10k downloads

Render Kroki diagrams.

Add to Obsidian
  • Overview
  • Scorecard
  • Updates9

Render Kroki Diagrams in Obsidian.

This plugin uses, by default, the Kroki server for rendering, but specifying an alternate one via this plugin's options is encouraged.

If you can't find an alternate, then you can host your own server as described here.

This plugin is a modified and slightly expanded version of the obsidian-plantuml plugin by Johannes Theiner.

Supported diagram types

Diagram type Code-block language Notes
BlockDiag blockdiag
BPMN bpmn
Bytefield bytefield
SeqDiag seqdiag
ActDiag actdiag
NwDiag nwdiag
PacketDiag packetdiag
RackDiag rackdiag
C4 with PlantUML c4plantuml
Ditaa ditaa
Diagrams.net (draw.io) diagramsnet Disabled by default — needs a self-hosted Kroki with the yuzutech/kroki-diagramsnet companion
Erd erd
Excalidraw excalidraw
GraphViz graphviz
Mermaid mermaid Disabled by default to avoid clashing with Obsidian's built-in Mermaid — enable and rename to e.g. kroki-mermaid
Nomnoml nomnoml
Pikchr pikchr
PlantUML plantuml Disabled by default to avoid clashing with the PlantUML plugin — enable and rename to e.g. kroki-plantuml
Structurizr structurizr
Svgbob svgbob
UMlet umlet
Vega vega
Vega-Lite vegalite
D2 d2
WireViz wireviz
WaveDrom wavedrom
DBML dbml
Symbolator symbolator
TikZ tikz

Anything else Kroki supports server-side should work too — pick an unused diagram-type slot in settings and set its kroki block name to the new type. PRs adding first-class entries for new types are welcome.

Usage

Create a fenced codeblock using one of the diagram types supported by kroki as the language. See the Kroki site for a complete list of supported diagram types. Specify your diagram code inside the codeblock.

On desktop the diagram is rendered as inline SVG, so links inside the diagram (e.g. GraphViz URL= nodes) stay clickable. On mobile, and as a fallback if the SVG can't be fetched, it is rendered as an <img>.

Below each diagram there are two small links: PNG downloads a PNG of the diagram, and Edit opens it in niolesk. The PNG link is omitted for diagram types whose Kroki server doesn't generate PNG output (BPMN, Bytefield, D2, DBML, Excalidraw, Nomnoml, Pikchr, Svgbob, Symbolator, WaveDrom).

Including diagram source from a file

Instead of writing the diagram inline, the codeblock body can be just:

```structurizr
@from_file:path/to/workspace.dsl
```

The path is relative to the vault root. The file's contents are used as the diagram source.

Settings

  • Server URL — the Kroki server to use (default https://kroki.io/). Self-hosting is encouraged.
  • White background — render diagrams on a white background; useful because Kroki returns transparent SVGs that can be unreadable on dark themes.
  • Diagram types — enable/disable each type and optionally change the code-block language it responds to. Changes take effect after Obsidian reloads. Types that accept a header — PlantUML, C4-PlantUML, Structurizr, Mermaid — show a full-width header textarea inside their own settings card; text typed there is prepended to every diagram of that type and is handy for shared themes, !includes, or Mermaid %%{init: …}%% directives. Each language's syntax is different, so each supported type has its own header. All other types (graphviz, d2, vega, tikz, …) have no header field — any non-empty prelude would break their parsers.

Types disabled by default

A few diagram types are shipped disabled because they need extra setup before they'll work:

  • mermaid and plantuml — disabled to avoid clashing with Obsidian's built-in mermaid code blocks and with the popular PlantUML plugin. To use Kroki's renderers, enable them in settings and rename the code-block language (e.g. kroki-mermaid, kroki-plantuml).
  • diagramsnet (draw.io) — Kroki renders diagrams.net via a separate companion service (the yuzutech/kroki-diagramsnet container, by default on port 8005). The public https://kroki.io instance does not run it; pointing the plugin there will get you Error 503: Connection refused. To use this type, host your own Kroki + diagramsnet companion (see Kroki install docs) and set Server URL accordingly.

Some other types (e.g. Excalidraw, BPMN) also rely on companion services; the public Kroki instance includes them, but a minimal self-host won't unless you start the companion containers too.

Examples

See kroki-test.md for examples of each of the currently supported diagram types.

Installation

Inside Obsidian

Settings > Third-party plugins > Community Plugins > Browse and search for Kroki.

Manually installing the plugin

  • Clone this repo
  • npm i to install dependencies (or nix develop for a pinned toolchain, then npm i)
  • npm run build
  • Copy over main.js, styles.css, manifest.json to your vault VaultFolder/.obsidian/plugins/obsidian-kroki/.
96%
HealthExcellent
ReviewPassed
About
Render Kroki diagrams in Obsidian by placing diagram code inside fenced code blocks labeled with any Kroki-supported language. Point to the default Kroki server or configure an alternate or self‑hosted Kroki instance for rendering.
DrawingVisualizationCode
Details
Current version
1.3.1
Last updated
2 days ago
Created
5 years ago
Updates
9 releases
Downloads
10k
Compatible with
Obsidian 0.13.25+
License
MIT
Report bugRequest featureReport plugin
Author
gregzurogregzuro
github.com/gregzuro/
GitHubgregzuro
  1. Community
  2. Plugins
  3. Drawing
  4. Kroki

Related plugins

Mermaid Tools

Improved Mermaid.js experience: visual toolbar with common elements and more.

tldraw

Integration with tldraw, allowing users to draw and edit content on a virtual whiteboard.

ABC Music Notation

Render music sheets directly from code blocks using ABC music notation via abcjs.

Excalidraw

Create and edit Excalidraw drawings.

Advanced Canvas

Supercharge your canvas experience. Create presentations, flowcharts and more.

Templater

Create and use dynamic templates.

Maps

Adds a map layout to bases so you can display notes as an interactive map view.

PlantUML

Generate PlantUML diagrams.

Life Tracker

Capture and visualize the data that matters in your life.

Strange New Worlds

Reveal networked thought and the strange new worlds created by your vault.