Regex Tester
Test and debug regular expressions in real-time with match highlighting and capture groups.
/
/
Test String
Matches
0
Enter a pattern and test string to see matches
Capture Groups
0
Capture groups will appear here
📖 Quick Reference — Common Regex Patterns
. Any character (except newline)
\d Digit [0-9]\D Not a digit\w Word char [a-zA-Z0-9_]\W Not a word char\s Whitespace\S Not whitespace\b Word boundary^ Start of string/line$ End of string/line* 0 or more+ 1 or more? 0 or 1 (optional){n} Exactly n times{n,m} Between n and m times
(...) Capture group(?:...) Non-capturing group
(?=...) Lookahead(?<=...) Lookbehind[abc] Character set[^abc] Negated seta|b Alternation (or)How to Use
- Type or paste your regex pattern in the input field at the top
- Toggle flags (g, i, m, s, u) using the buttons next to the pattern
- Enter your test string in the text area — matches highlight in real-time
- View all matches and capture groups in the results panels below
- Use preset patterns (Email, URL, IP, etc.) to quickly test common regex
- Click items in the Quick Reference to insert patterns into the regex field