Skip to content
| Marketplace
Sign in
Visual Studio Code>Visualization>Flowgraph StudioNew to Visual Studio Code? Get it now.
Flowgraph Studio

Flowgraph Studio

Flowgraph Studio

|
1 install
| (0) | Free
Preview and edit Mermaid diagrams in .mmd files and Markdown exactly as Flowgraph Studio draws them: saved positions, rich nodes, icons and themes. Drag, connect and restyle on a visual canvas, with every change written back into the file. Export SVG and PNG.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Flowgraph Studio for VS Code

See your Mermaid diagrams in VS Code exactly as Flowgraph Studio draws them: saved positions, rich nodes with icons, and your repository's theme. Preview .mmd files and Markdown blocks as you type, edit them visually on Flowgraph's canvas with every change written back into the file, and export SVG and PNG.

Everything is drawn and edited on your computer. Nothing is sent anywhere unless you choose Open on flowgraph.studio or sign in.

A Mermaid file in VS Code beside the Flowgraph preview, which draws it with icons in the Midnight theme

Preview a diagram

Open a .mmd or .mermaid file, then:

  • click Open Preview to the Side in the editor's title bar, or press Ctrl+K V (Cmd+K V on a Mac);
  • press Ctrl+Shift+V (Cmd+Shift+V) to open the preview in place of the editor;
  • or right-click the file in the Explorer and choose Open Preview.

The preview redraws as you type, before you save. Drag to move around, hold Ctrl (Cmd) and scroll to zoom, or use −, +, Fit and 100%. With the preview focused, +, - and 0 do the same.

Diagrams saved from Flowgraph Studio keep their layout: the positions you set on the website travel in the diagram's code, so the preview draws them where you put them.

Edit visually

Choose Edit Visually in the editor's title bar (or the line of links at the top of a .mmd file, or above a Markdown block). Flowgraph's canvas opens beside the code: drag and resize nodes, connect them, add nodes and icon nodes, run Auto layout, and pick themes, colours and fonts in the Style panel.

Flowgraph's visual editor in VS Code beside a Mermaid file: a node was dragged, and the file's last line now holds the saved positions

The file is the only copy. Each change is an ordinary edit of it, so Undo, Save, the unsaved dot and git work as they do for typing, and typing in the code redraws the canvas. Positions are kept in a %% flowgraph-layout: comment line and the style in a %% flowgraph-theme: line, which other Mermaid tools ignore. On a Markdown block, only the block's lines change.

Diagrams in Markdown

Click Preview in Flowgraph above any ```mermaid block. The preview follows your cursor: move into another block and it draws that one.

A README in VS Code with links above its Mermaid block, and that block drawn in the Flowgraph preview

VS Code's own Markdown preview draws the blocks with Flowgraph too, in your theme and with icons.

VS Code's Markdown preview showing a README with its Mermaid diagram drawn by Flowgraph

Mistakes, in plain words

A mistake is explained at the bottom of the preview, with the last good drawing kept behind it, and listed in the Problems panel on the line where it is.

An unfinished arrow in a Mermaid file: the preview explains it, and the Problems panel lists it on its line

Styles

Previews use the same style as your diagrams elsewhere, looked up in this order:

  1. The diagram's own %% flowgraph-theme: line, which Export → Mermaid code on the website and the visual editor write.
  2. The theme: file in the repository's flowgraph.yml, so previews match the images CI renders with flowgraph sync.
  3. The flowgraph.theme setting: a preset's name (Midnight, Blueprint CAD, Sage Notebook…), or a theme file exported from Flowgraph Studio with Export → Theme JSON.
  4. Otherwise Glass.

In a folder you haven't trusted, the folder's own flowgraph.theme setting is ignored, so a cloned repository can't point it at files elsewhere on your computer.

Export

Click Export… in the preview, or run Flowgraph: Export Diagram…, and choose:

  • PNG at 1×, 2× or 3×, with the theme's background or a transparent one;
  • or SVG, with its fonts embedded so it looks the same in any app.

Images are made exactly as flowgraph.studio makes them. Signed out, they carry the small Flowgraph Studio watermark, as signed-out exports there do. Signed in, your plan decides: Free has 10 watermark-free exports a month (shared with the website, and each version of a diagram counts once), and Pro has no limit.

Sign in

Everything above works without an account. Signing in brings your plan into VS Code:

  • Pro icons: Gen AI icons (@icon:genai:…) draw in previews on Pro and Pro Max;
  • Exports: your watermark-free exports, as on the website.

Click Sign In in the Flowgraph Studio view in the activity bar, or choose Sign in with Flowgraph Studio from the Accounts menu. Your browser opens flowgraph.studio, where you approve the connection; you're then sent back to VS Code. The connection is an API key named after your editor, kept in your system's keychain, and listed in Account settings → Render API on the website, where you can revoke it. Sign Out gives it back.

If your browser can't send you back to the editor (some remote setups), run Flowgraph: Sign In with API Key and paste a key from Account settings → Render API.

Saved diagrams and linked files (Pro)

The Saved Diagrams section of the Flowgraph Studio view lists the diagrams in your account, by project. Click one to open it, read-only, in its own style with its preview; use Save into Workspace… to make it a .mmd file linked to it, or open it on flowgraph.studio.

A Mermaid file in your workspace can be linked to a saved diagram: Save to Flowgraph Studio (in the line of links at the top of the file, the editor's … menu, or the file's right-click menu) saves it to your account and links it. Then the line at the top offers:

  • Push sends the file's changes to the saved diagram;
  • Pull brings changes made on flowgraph.studio, such as a layout arranged on the canvas, into the file;
  • if both changed since the last push or pull, you choose: compare them, keep the file's code (the site's version is kept in the diagram's version history first), or take the site's (it replaces the file's code; Undo or your version control brings it back).

Saved diagrams belong to your account, so links are kept by VS Code for you in this workspace, not in the repository; a teammate links their own copy. A linked file shows Flowgraph in the status bar, with the same actions.

Diagrams from your code

Right-click a folder or a source file in the Explorer (or run Flowgraph: Draw Code Diagram…) and choose:

  • Codebase map: folders by role, entry points and sizes;
  • Module dependencies: which folders or files import which;
  • Route map: endpoints, pages and commands, and their handlers;
  • Class diagram, Call map (a folder, or one file), or Function flowchart (the function your cursor is in, or one you pick).

TypeScript, JavaScript, Python, Java, Go and C# are read. The diagrams are drawn on your computer by the same code as flowgraph-cli and the website, with no account and no network: your code never leaves the machine. They open as Markdown with notes on anything left out, with the first diagram in the preview; save the file, or open a diagram on flowgraph.studio.

Keep README diagrams up to date

If the repository has a flowgraph.yml (see Keep README diagrams up to date in CI), Flowgraph: Sync Diagrams runs it as CI does: it draws each diagram it lists, renders the images that changed, and fills in the README's blocks. Changed files appear in Source Control. Check Diagrams Are Up to Date changes nothing and says whether anything is out of date. Rendering images uses your signed-in account's API renders (or FLOWGRAPH_API_KEY); Mermaid outputs need no account.

Code diagrams and sync read the folder's files (and sync writes them), so they run only in a folder you trust.

Open on flowgraph.studio

Open on flowgraph.studio (in the preview's title bar, a file's menus, the command palette, and above each Markdown block) opens the diagram in the web editor, with its name and style, to drag, style and share it. The diagram travels in the link itself, after the #, which browsers don't send to the server; the page asks before adding it. Signed in, it's then saved to your account like any other diagram.

Settings

Setting Default What it does
flowgraph.theme (empty) A preset's name, or a theme file. flowgraph.yml comes first.
flowgraph.codeLens on The line of actions above diagrams: Preview, Open on flowgraph.studio, and in Mermaid files Save, Push and Pull.
flowgraph.markdownPreview on Draw Mermaid blocks in VS Code's Markdown preview.

Requirements

VS Code 1.90 or later. The extension is also on Open VSX, for editors that install from there.

Licence

Free to use, under the licence included with the extension (its LICENSE file). The bundled open-source packages and icon sets, and their licences, are listed in dist/THIRD-PARTY-LICENSES.txt. Privacy · Guide · Contact

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft