What is Mermaid?
Mermaid turns text definitions into diagrams. Because the source is text, teams can review it in pull requests, track changes with Git, and keep diagrams close to the documentation they explain.
The editor renders flowcharts, sequence diagrams, class diagrams, entity-relationship diagrams, and Gantt charts locally. Start with a template, change the source, then export SVG or PNG.
Choose the right diagram
- Flowcharts explain decisions and processes.
- Sequence diagrams show messages between systems over time.
- ER diagrams document entities and database relationships.
- Class diagrams describe types, members, and inheritance.
- Gantt charts communicate schedules and dependencies.
A minimal flowchart
flowchart LR
Request --> Validate{Valid?}
Validate -->|Yes| Publish
Validate -->|No| ReviseSafe local rendering
The source is saved in this browser's localStorage and is not uploaded by DevToy. Rendering uses Mermaid's strict security mode, which disables unsafe HTML and interactive links in diagram labels.
Frequently asked questions
Which export should I use?
Use SVG for documentation and design tools because it scales cleanly. Use PNG when a destination does not accept SVG.
Why does a valid-looking diagram fail?
Check the diagram keyword, indentation, reserved words, quotes, and version-specific syntax. Start from the nearest template and add lines gradually.
Is my diagram saved?
The current source is saved locally on this device so it can be restored after a refresh. Clearing browser storage removes it.