Regex Tester
Test JavaScript regular expressions live: highlight matches, inspect numbered and named capture groups, toggle flags and preview replacements.
Runs locally · nothing uploaded
How to use the Regex Tester
- 1
Enter a pattern and toggle flags (g, i, m, s, u, y).
- 2
Type or paste test text and see every match highlighted.
- 3
Inspect numbered and named capture groups, and preview a replacement using $1 or $<name>.
What happens to your data
Patterns and test text are evaluated in your browser only.
Frequently asked questions
Which regex flavour does it use?
Your browser's JavaScript RegExp engine, so results match what your JavaScript or TypeScript code will do.
Why do I only get one match?
Without the g (global) flag a regular expression stops after the first match. Turn g on to find them all.

