FreeNo sign-upNothing uploadedPNG download

State Diagram Generator

Describe the states of an order, a ticket or a device as text — get a state machine diagram instantly. Paste Mermaid stateDiagram-v2 code — or start from the example — and this free online state diagram generator renders it in your browser, ready to download as a crisp PNG. No sign-up, and nothing you paste leaves your device.

Rendering your state diagram…

The demo above is live — edit the code and hit Generate. The example that loads with the page is free; each Generate click uses one of your 10 free generations per day.

How it works

From states written as text to a state machine diagram in four steps.

1

List your states

What can the thing be — Pending, Paid, Shipped — and which event moves it from one to the next.

2

Turn it into Mermaid code

Write the transitions as lines like Paid --> Shipped: order fulfilled — or let ChatGPT or Claude write the code for you.

3

Pick “Mermaid diagram” and hit Generate

The visual type is pre-selected on this page. Your state diagram is drawn instantly in your browser — nothing is uploaded.

4

Download PNG

One click, no watermark — ready for design docs, wikis or slides.

What goes into a state diagram

Three building blocks describe any state machine — and all three are just text.

State

States

Rounded boxes are the conditions your thing rests in over time — an order that is Pending, Paid or Delivered.

Transition

Transitions

Arrows connect states; the label after the colon is the event that triggers the move, like “payment confirmed”.

Marker

Start & end

[*] marks where the lifecycle begins and which states are final — Closed or Cancelled in the example above.

From text to state diagram, the AI-friendly way

You never have to write Mermaid by hand: describe the lifecycle to ChatGPT or Claude and paste what it returns here — no sign-up, and everything renders locally on your device.

Step 1

Describe your lifecycle in English

Tell ChatGPT or Claude what happens — “an order goes pending, paid, shipped, delivered, closed; it can be cancelled before shipping” — and ask for Mermaid stateDiagram-v2 code.

Step 2

Paste the code here

Copy the state diagram code it returns and drop it into the box above, skipping the fence lines around the code block.

Step 3

Generate, download PNG

Hit Generate: the state machine draws instantly in your browser and exports as a crisp, watermark-free PNG for docs and slides.

Private by design: your state diagrams never leave your browser

State machines often describe how internal systems really work. Text2Viz renders them locally, so nothing is uploaded.

Privacy

No sign-up, no account

There is nothing to create and nothing to log into. Open the page and start diagramming.

Privacy

Rendered locally

Your diagram is drawn by JavaScript running on your own device. Your state text is never sent to our servers.

Privacy

Safe for internal systems

Order pipelines, ticket workflows, device firmware modes — render them here without a second thought.

What people make with it

Three common ways people use this free state diagram generator.

Use case

Model an order or ticket lifecycle

Show every state an order can reach — including the unhappy paths like Cancelled — before you write the code.

Use case

Design a device or workflow controller

States and events make embedded modes, approval chains and job pipelines explicit and reviewable.

Use case

From AI chat to image

ChatGPT or Claude drafted your lifecycle as stateDiagram code? Paste it here and export a shareable PNG.

Frequently asked questions

Is this state diagram generator free?
Yes. You get 10 free diagram renders per day, every day, with PNG download and no watermark. No account, no trial that expires.
How do I turn text into a state diagram online?
Write your diagram as Mermaid stateDiagram-v2 syntax: start the first line with stateDiagram-v2, add transitions like Pending --> Paid: payment confirmed, and mark the start and end states with [*]. Hit Generate and the state diagram draws instantly — no sign-up.
What is the difference between a state diagram and a flowchart?
A flowchart describes the order of actions — each box is a step that happens once. A state diagram describes the states a thing can be in over time — Pending, Paid, Shipped — and which events move it from one state to the next. Use a flowchart for how work flows through a process, and a state diagram for the lifecycle of an order, a ticket or a device.
How do I show a decision or fork in a state diagram?
Declare a choice state with state choose <>, point transitions into it, and branch out of it with labels like : yes and : no. You can also give states friendlier display names without touching the code — state "Out of stock" as Backordered.
Can AI write the stateDiagram code for me?
Yes. Describe your states and the events that move between them to ChatGPT or Claude and it will output Mermaid stateDiagram-v2 code — paste the code block here (skip the fence lines) and render it into a diagram.
Can I download the state diagram as a PNG?
Yes. Every diagram has a Download PNG button — free, no watermark, exported at double resolution so state names and transition labels stay readable in docs and slides.

More text-to-diagram tools

The same paste-and-generate flow, tuned for other diagram types.

Diagram maker

Flowchart Maker

Process steps and decision branches from Mermaid flowchart syntax.

Diagram maker

ER Diagram Maker

Entity relationship diagrams for database schemas from Mermaid erDiagram syntax.

Diagram maker

Class Diagram Generator

UML class diagrams for domain models from Mermaid classDiagram syntax.

Diagram maker

User Journey Map Generator

Map customer journey steps, satisfaction scores and actors from Mermaid journey syntax.

Diagram maker

Pie Chart Generator

Turn labels and values into a pie chart with Mermaid pie syntax.

Diagram maker

Quadrant Chart Generator

Plot options on a 2x2 matrix with Mermaid quadrantChart syntax.

Diagram maker

Git Graph Generator

Visualize commits, branches and merges with Mermaid gitGraph syntax.

Diagram maker

Sankey Diagram Maker

Show how budget, energy or users flow between stages with Mermaid sankey-beta code.

Diagram maker

Block Diagram Maker

Lay out system components in a grid of blocks and arrows from Mermaid block-beta code.

Diagram maker

Requirement Diagram Maker

Map requirements, elements and satisfies links from Mermaid requirementDiagram code.

Diagram maker

C4 Context Diagram Maker

Draw a C4 context diagram — people, systems and relationships — from Mermaid C4Context code.

Diagram maker

C4 Container Diagram Maker

Zoom inside a system's containers with Mermaid C4Container syntax.

Chart maker

XY Chart Maker

Line and bar charts with axes and a title from Mermaid xychart-beta code.

Timeline

Text to Timeline Maker

Dates and events become a clean horizontal timeline. Also see the horizontal, project and history timeline makers.

Have states? Draw them.

Free, no sign-up, 10 renders a day.

Generate my state diagram