Regex Tester
Test a JavaScript regular expression against your text and see every match with its position and capture groups in a table.
Regex Tester runs a JavaScript regular expression against your text and lists every match in a table with its position and capture groups, including named groups. A pattern that runs too long is stopped instead of freezing the page.
What is a regular expression?
Regular expression
A pattern that describes text, such as \d{4}-\d{2}-\d{2} for a date. Parentheses capture parts of a match, and (?<name>...) gives a capture a name. Flags change behaviour: i ignores case, m makes ^ and $ work per line, s lets the dot match new lines.
Why use Regex Tester?
- See every match. All matches are listed, not just the first, with the index where each starts.
- Groups in columns. Each capture group gets its own column, labelled with its name when it has one.
- Safe to experiment. Matching runs in a background worker with a three-second limit, so a runaway pattern cannot hang your tab.
How to use Regex Tester, step by step

- Paste your test text into Regex Tester. Or use the example.
- Type the pattern and flags. Write the pattern without the surrounding slashes. The g flag is always on so every match is found.
- Read the table. It updates as you type. Copy or download it as CSV.
Frequently asked questions
Which regex flavour does it use?
JavaScript, as built into your browser. Most syntax matches PCRE and Python, but features such as possessive quantifiers and recursion are not available.
Why are backslashes doubled in my code but not here?
In a JavaScript string, a backslash must be escaped. Here you type the pattern itself, so write \d, not \\d.
Is there a limit on matches?
The table stops at 1,000 matches to stay responsive, and says so.
Looking for the long version? The guides cover each of these jobs in depth.