# Flow to Mermaid Diagram

**URL:** https://discourse.nodered.org/t/flow-to-mermaid-diagram/95871
**Category:** General
**Tags:** dashboard-2
**Created:** [8 March 2025 10:26 UTC](https://discourse.nodered.org/t/flow-to-mermaid-diagram/95871 "2025-03-08T10:26:10Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![SandeepA](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/sandeepa/32/63225_2.png) [@SandeepA](https://discourse.nodered.org/u/SandeepA)
#### Post date: [8 March 2025 10:26 UTC](https://discourse.nodered.org/t/flow-to-mermaid-diagram/95871/1 "2025-03-08T10:26:10Z")

</div>

Hi  
I found this amazing link.  
Installed and tinkered with it - and works gives very good results.

> [@Node-RED flow to Mermaid diagram](https://discourse.nodered.org/t/node-red-flow-to-mermaid-diagram/81412):
>
> Hi There! I've been playing around with [Mermaid](https://mermaid.js.org/) diagrams for a while and now that in version 3.1.x they are officially supported, I've created a [convertor flow](https://flowhub.org/f/6e54d62e53ab5b6d) that takes your node-red flow and generates a Mermaid flow diagram. It does this with a non-deployed flow, i.e. what see in the editor, is what you get. I've put in a few different shapes so that some node types can be differentiated and also if possible, a dashed line between link-out and link-in nodes. I'm sure its buggy and broken b…

Have asked the author - if this can be converted into a standard node.  
It takes input as flow json (for a tab) and gives the diagram as output.

This combined with NR apis and NR Dashboard - can allow creating automatic Mermaid diagrams for user to visualize.

We can also create flow which will automatically update the info property for a flow and post it back - so that even in editor the diagram gets created automatically.

Any ides how can this be done - would be welcome .

---

<div class="post-metadata">

### Author: ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)
#### Post date: [8 March 2025 10:37 UTC](https://discourse.nodered.org/t/flow-to-mermaid-diagram/95871/2 "2025-03-08T10:37:24Z")

</div>

Dashboard 2 already has built in support for mermaid diagrams.

> **[Markdown Viewer ui-markdown | Node-RED Dashboard 2.0](https://dashboard.flowfuse.com/nodes/widgets/ui-markdown.html#mermaid-charts)**
>
> Present text and documentation elegantly with ui-markdown viewer in Node-RED Dashboard 2.0.

---

<div class="post-metadata">

### Author: ![SandeepA](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/sandeepa/32/63225_2.png) [@SandeepA](https://discourse.nodered.org/u/SandeepA)
#### Post date: [8 March 2025 11:02 UTC](https://discourse.nodered.org/t/flow-to-mermaid-diagram/95871/3 "2025-03-08T11:02:24Z")

</div>

Right. Hence i need a node which will convert flow to Mermaid diagram which then i can feed to ui-markdown.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [6 June 2025 11:02 UTC](https://discourse.nodered.org/t/flow-to-mermaid-diagram/95871/4 "2025-06-06T11:02:51Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
