Flags
g, i, m, s, u and y — global, case-insensitive, multiline, dotAll, Unicode and sticky. Toggle each with one click.
Test regular expressions live — with match highlighting, capture groups, every flag and a replace mode. Everything runs in your browser.
hello@svcs.bgat 8support@example.comat 25g, i, m, s, u and y — global, case-insensitive, multiline, dotAll, Unicode and sticky. Toggle each with one click.
See the value of every numbered ($1, $2) and named (?<name>) group for each match.
Replace matches using $1, $2 and $<name> backreferences — just like in JavaScript.
A regular expression is a search pattern for text. You describe a model — such as "an email address" or "a date" — and then find, validate or replace every match in a string. This tester uses JavaScript (ECMAScript) syntax.
All six JavaScript flags: g (global — all matches), i (case-insensitive), m (multiline — ^ and $ match per line), s (dotAll — the dot also matches newlines), u (Unicode) and y (sticky). Toggle them with the checkboxes.
Every set of parentheses ( ) in the pattern creates a group. For each match the tester lists the values of numbered groups ($1, $2, …) and named groups (?<name>…), so you can see exactly what was captured.
Yes. Turn on "Replace mode" and enter a replacement string. Backreferences are supported — $1, $2 for numbered groups and $<name> for named ones — exactly like JavaScript’s String.prototype.replace.
No. The pattern and the test string are processed entirely in your browser using the built-in JavaScript regular-expression engine — nothing is uploaded to a server.