DeveloperTool 04
Regex Tester
Iterate on a pattern without guessing. Matches are highlighted in the sample text, with capture groups and positions listed below.
Run pattern
19 / 232Result
WaitingRun the tool and the result appears here. Copy it or download it — nothing leaves this tab.
Privacy
Everything you type stays in this tab and is processed by JavaScript on your device. Nothing is uploaded, logged or stored on a server.
How to use it
Enter a pattern and flags. The pattern is compiled as a JavaScript regular expression.
Paste sample text; matches are highlighted and listed with their indexes.
Optionally add a replacement string to preview a substitution.
When to use it
Validation rules
Check an email or slug pattern against realistic samples.
Log parsing
Prototype an expression against a pasted log line.
Find and replace
Preview a substitution before running it in an editor.
Questions
Which regex dialect is used?
JavaScript regular expressions, as implemented by your browser. Lookbehind support depends on the browser.
Why are only 500 matches scanned?
The cap keeps the page responsive on pathological patterns. Narrow the pattern or text for a complete list.
Does my text leave the page?
No. Matching happens in the browser tab.
Is this a JavaScript regular expression tester?
Yes. The pattern is compiled with the JavaScript engine in your browser, so it behaves like the one in your app. Dialects such as PCRE and Python's re module differ on some constructs, so do not assume identical results there.
How do I see capture groups and match positions?
Matches are highlighted in the sample text and listed below with their start index; numbered groups appear with each match. Adding a replacement string previews a substitution without changing your input.