Docs · Engines

Railroad / syntax diagram

Native railroad (syntax) diagrams for grammars, json.org style. One production per block — `rule ::= term | other` — with sequences, stacked `|` choices, `[optional]` bypasses, `{repetition}` loops and `(grouping)`. Quoted terminals render as rounded pills, bare nonterminals as rectangles, and every rule in the document renders as its own stacked diagram. The standard way language and API docs explain syntax.

Templates
10
Source language
plaintext
Workstation
Studio
Engine id
railroad

In the same space

Most users come to Railroad / syntax diagram from railroad-diagrams (tabatkins), Hand-drawn EBNF figures or bottlecaps.de/rr. Glyph runs this engine in the browser — no install, shareable via URL, exportable to PNG / SVG / PDF / source.

Syntax at a glance

value ::= object | array | "true" | "false"
object ::= "{" [ pair { "," pair } ] "}"

Paste this in the Studio code pane to see Railroad / syntax diagram render live. The full grammar is at the upstream-docs link above.

Sample templates

All 10
Engine reference: railroad · ← Browse all engines · Quick-start guide