Text Utilities
Test regular expressions with live match highlighting, capture group inspection, and common pattern presets.
Test Text box.Regex Pattern field — highlighting updates live as you type.g, i, m, s, and u flags to change matching behavior (global, case-insensitive, multiline, dotall, Unicode).Presets dropdown — Email, URL, Phone (US), IPv4, Date, or Hex Color.Highlighted Matches panel for a live view of every match, then check Capture Groups to see each group's value.Copy to copy the test text, or Clear to reset it and start over.See matches and capture groups update as you edit, so you can refine a pattern without rebuilding an app or adding logging.
Live highlighting shows exactly which substrings each pattern hits — far easier to read than staring at raw match output.
Confirm exactly what each parenthesized group extracts before wiring the pattern into parsing or replacement code.
Try the built-in presets for email, URL, phone, IPv4, date, and hex color against real data before shipping them.
Toggle g, i, m, s, and u to see how case-sensitivity, multiline, dotall, and Unicode change results.
Everything runs in your browser. Your patterns and text are never uploaded, logged, or sent to a server.
It compiles your pattern into a JavaScript RegExp, runs it against the text you provide, highlights every match, and lists the capture groups for each match.
g is global (find every match, not just the first), i is case-insensitive, m makes ^ and $ match at line boundaries, s lets . match newlines, and u enables full Unicode matching. Only g is on by default.
Your pattern has a syntax error — for example an unclosed group or an invalid quantifier. The message shows the browser's error, and the match count reads Error until you fix it.
A match is the whole substring the pattern found. Capture groups are the parts inside parentheses (…), listed as Group 1, Group 2, and so on — useful for pulling out just the pieces you need.
No. Enter just the pattern body, for example \d{3}-\d{4}, without /.../ delimiters. The pattern is passed directly to the JavaScript engine.
Whatever your browser's JavaScript engine supports works here, since the pattern compiles to a native RegExp. Enable the u flag for proper Unicode handling of emoji and astral characters.
Never. All matching happens locally in JavaScript. Your text and patterns are not sent to, stored on, or logged by any server.