Regular Expression Tester

Test and validate your regular expressions in real-time with this comprehensive regex tester tool.

Regex Flags
Regular Expression Pattern
/
/
g
Test String
Results
Match Information:
No matches found
Quick Reference
Character Classes
  • . - Any character except newline
  • \w - Word character [a-zA-Z0-9_]
  • \d - Digit [0-9]
  • \s - Whitespace character
  • \W - Non-word character
  • \D - Non-digit
  • \S - Non-whitespace character
Anchors
  • ^ - Start of string/line
  • $ - End of string/line
  • \b - Word boundary
  • \B - Non-word boundary
Quantifiers
  • * - 0 or more
  • + - 1 or more
  • ? - 0 or 1
  • {n} - Exactly n times
  • {n,} - n or more times
  • {n,m} - Between n and m times
Groups & Ranges
  • (abc) - Capture group
  • (?:abc) - Non-capturing group
  • [abc] - Character set
  • [^abc] - Negated character set
  • [a-z] - Character range
  • a|b - Alternation (a or b)
Special Characters
  • \ - Escape character
  • \t - Tab
  • \n - Newline
  • \r - Carriage return