Tool info
Regex Tester
Pattern
Test text
Regex token quick referenceToken reference for common regex patterns.
- .
- Any character (except newline)
- \d
- Digit (\D non-digit)
- \w
- Word character (\W non-word)
- \s
- Whitespace (\S non-space)
- \b
- Word boundary
- ^ $
- Start / end of string (or line with m)
- * + ?
- Zero or more / one or more / optional
- {n,m}
- Exactly n to m repetitions
- […]
- Character class, e.g. [a-z0-9]
- (…)
- Capturing group
- (?:…)
- Non-capturing group
- (?<name>…)
- Named capturing group
- (?=…) (?!…)
- Lookahead (positive / negative)
- (?<=…) (?<!…)
- Lookbehind (positive / negative)
- a|b
- Alternation (a or b)
- \1 … \9
- Backreference to capture group
- \p{L}
- Unicode property (requires u flag)
- \x{…}
- Unicode code point (requires u flag)
Uses JavaScript regular expressions.