About This Regex Tester & Generator
Write or generate a regular expression and test it against your own text. Syntax errors are shown instantly, matches are highlighted as you type, and the match table lists every capture group. Patterns use JavaScript regex syntax and everything runs in your browser.
How to Use It
- 1Pick a ready-made pattern under Generate, or type your own regular expression.
- 2Turn flags on or off: g (global), i (ignore case), m (multiline), s (dotAll), u (unicode).
- 3Paste your test text. Matches are highlighted and listed with their capture groups.
- 4Optionally turn on Replace to preview a find-and-replace using $1 or $<name>.
- 5Copy the pattern, or the full /regex/flags literal, into your code.
