Ghost RegexWork with regular expressions right inside VS Code. No browser tabs, no copy-paste, no surprises in production. Railroad diagrams, Explain with AST tree, ReDoS detector with auto-fix, Unit tests, and Preview on real files — all in one extension. Works fully offline. What it does📊 Railroad diagramEvery token — visualized. Anchors in green, groups in purple, quantifiers in orange. Hover for tooltips with explanations. Export to SVG with one click.
🌳 Explain and AST treeParses regex into 100+ token types. Clear nesting structure — groups, quantifiers, lookaround. You see what the pattern actually does. 🛡️ ReDoS detector with auto-fixFinds nested quantifiers before they become a problem. Shows vulnerability level (low / high / critical). Suggests a fixed pattern in one click.
🔍 Preview on real filesPick a file — the extension highlights matches right in the content. Not in a sandbox, not on made-up strings. On real data. ✅ Unit tests for regexSave test strings with expected results — run the pattern against the whole set with one button. Failed — you'll see a red ✗ on that specific test. 🔄 Convert to 5 languagesOne regex — code for Python, JavaScript, Go, Rust, Java. With proper escaping. ⚡ 94 snippetsEmail, URL, IPv4, UUID, JWT, dates, passwords — 8 categories of ready-made patterns. Paste and go.
↩️ Sync BackRight-click on regex in code → "Explain selection" → edit in panel → "Apply to editor". All in one place. Keyboard shortcuts
Free vs ProFree — full-featured tool, not a demo:
Pro — $6/month:
PrivacyEverything runs locally inside VS Code. Preview reads files from your disk. ReDoS analysis runs on your machine. No server requests, no telemetry, no accounts. Your patterns stay yours. Requirements
FeedbackFound a bug or have an idea? Open an issue or use the feedback form on our landing page. LicenseMIT |


