Highlighted Matches
Capture Groups
How to use the Regex Tester
- Enter your regular expression pattern in the Pattern field.
- Enable flags as needed:
gfinds all matches,iignores case,mmakes^and$match line boundaries. - Paste your test string β matches are highlighted in real time and capture groups are shown below.
JavaScript regex syntax quick reference
. matches any character. \d matches a digit, \w a word character, \s whitespace. Use + for one or more, * for zero or more, ? for optional. Wrap groups in (β¦), alternation in a|b, character classes in [β¦]. Use \b for word boundaries.