Test regular expressions live
This regex tester runs your JavaScript regular expression against any text and highlights every match as you type. Toggle the flags you need (global, ignore case, multiline, dotall, unicode, sticky), and see a table of matches with their capture groups. If the pattern is invalid, you get the error message right away. Everything runs locally in your browser.
Understanding the flags
- g (global) finds all matches instead of stopping at the first.
- i (ignore case) makes the match case-insensitive.
- m (multiline) lets ^ and $ match at line breaks.
- s (dotall) lets the dot match newline characters.
- u (unicode) enables full unicode matching, and y (sticky) anchors the search to the last index.
Frequently asked questions
How do I test a regular expression?
Type your pattern, choose the flags, and paste your test string. Matches are highlighted instantly and listed with their groups.
Which regex syntax does it use?
It uses the browser's native JavaScript engine, so it matches the behavior of regular expressions in JavaScript and Node.
Does it show capture groups?
Yes. When your pattern has capture groups, each match is listed in a table with its group values.
Is my pattern or text sent anywhere?
No. The regex runs entirely in your browser and nothing is uploaded.