What this does
Edit the pattern, flags, or test string and watch matches highlight live.
Each match expands to show its capture groups (positional $1, $2
and named ?<name>).
Flag reference
g— global. Find all matches (we always add this internally so the counter works).i— ignore case.m— multiline.^and$match start/end of each line.s— dotall..matches newlines.u— unicode. Treats the pattern as a sequence of Unicode code points.y— sticky. Matches only atlastIndex.
JavaScript regex quirks to know
-
Backslashes need escaping in some inputs. Here, you can type them as-is
(
\d, not\\d) — what you see is what gets compiled. -
Named groups use
(?<name>…). They appear in thegroupsobject on each match. -
Lookbehind (
(?<=…),(?<!…)) is supported in all modern browsers (ES2018+).
Is my data private?
Yes. Pattern compilation and matching happen entirely in your browser via
the built-in RegExp. Nothing leaves your device.