Regex Tester

Test regular expressions in real-time

/ /

Quick Reference

Character Classes

.Any character
\dDigit [0-9]
\wWord [a-zA-Z0-9_]
\sWhitespace
[abc]a, b, or c
[^abc]Not a, b, or c

Quantifiers

*0 or more
+1 or more
?0 or 1
{n}Exactly n
{n,}n or more
{n,m}Between n and m

Anchors

^Start of string
$End of string
\bWord boundary

Groups

(abc)Capture group
(?:abc)Non-capture
a|ba or b