Regex Tester & Debugger

Test regular expressions in real time. Highlights all matches, shows capture groups, and supports replace mode — all in your browser.

✓ Live Matching✓ Capture Groups✓ Replace Mode✓ Common Patterns
/ /
Ready Matches: 0 Groups: 0 Time: —
Test String
Matches
Run a pattern to see matches here.
Replace:

Quick Reference

.Any char except newline
\dDigit [0-9]
\wWord char [a-zA-Z0-9_]
\sWhitespace
^Start of string
$End of string
*0 or more
+1 or more
?0 or 1 (optional)
{n,m}Between n and m times
[abc]Character class
(a|b)Alternation
(?:…)Non-capturing group
(?=…)Positive lookahead
\bWord boundary
$1 $2Back-references