← Back to tools
/ /
Enter a pattern and test string

Quick Reference

Characters

.Any character except newline
\dDigit (0-9)
\wWord character (a-z, A-Z, 0-9, _)
\sWhitespace
\bWord boundary

Quantifiers

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

Groups & Flags

(abc)Capture group
(?:abc)Non-capture group
[abc]Character class
a|bAlternation
^ / $Start / end of line

Flags

gGlobal (all matches)
iCase insensitive
mMultiline (^ $ per line)
sDot matches newline
uUnicode support