Regex Tester
Test a regular expression against your text and see matches and capture groups highlighted in real time. Pick flags, inspect groups, and catch errors — all in your browser.
About Regex Tester
Regular expressions are powerful but easy to get subtly wrong. This tester runs your pattern against a sample string as you type, highlights every match, and lists the capture groups for each one, so you can see exactly what your regex does. Toggle flags like global, case-insensitive, and multiline, and get a clear error if the pattern is invalid. Everything runs locally using the browser's own regex engine.
Frequently asked questions
Which regex flavour is this?+
JavaScript (ECMAScript) regular expressions, the same engine your browser and Node.js use. Syntax is close to but not identical to PCRE or Python's re.
What do the flags mean?+
g finds all matches, i ignores case, m makes ^ and $ match line boundaries, s lets the dot match newlines, u enables full Unicode, and y anchors matching to a position.
Why does my pattern show an error?+
The pattern isn't valid JavaScript regex — often an unescaped special character or an unbalanced bracket or parenthesis. The error message describes the problem.