Regex Tester
What is Regex Tester?
Free online regex tester that validates and runs regular expressions against your text with real-time highlighted matches, named and numbered capture groups, flag toggles and a replacement preview for building and debugging patterns.
How to Use
- 1 Enter pattern — Enter the regular expression pattern.
- 2 Select flags — Select flags (g, i, m, s, u, y).
- 3 Enter test string — Enter the test string and match results are displayed in real-time.
- 4 Check results — Matched parts are highlighted in yellow and capture groups are shown in a table.
- 5 Replacement mode — In replacement mode, you can reference capture groups with $1, $2, etc.
Related Tools
Frequently Asked Questions
Ten presets are provided including email, URL, IPv4, Korean phone number, HEX color, HTML tag, and date patterns.
Yes. Named capture groups in the format (?<name>pattern) are supported and displayed in the results table.
Pattern validity is checked in real-time, displaying a red border and error message.
When matching empty strings, lastIndex is automatically incremented, with a maximum limit of 10,000 iterations.
No. All regex processing is performed in the browser.