Skip to main content

Regex Tester

Test regular expressions with live match highlighting, capture groups, and replace mode. 100% in-browser.

Flags:
Ready
0 chars
Test String 0 chars
Matches
0
Matches
0
Groups

Enter a pattern and test string to see matches

Frequently Asked Questions

Does the Regex Tester send my patterns or test strings to a server?

No. All regex matching, highlighting, and replacement happens entirely in your browser using JavaScript's native RegExp engine. Your patterns and test data never leave your device.

What regex flags are supported?

The tester supports all standard JavaScript regex flags: g (global — find all matches), i (case-insensitive), m (multiline — ^ and $ match line boundaries), s (dotAll — dot matches newline), and u (Unicode mode). Toggle any combination of flags using the flag buttons.

How do I use named capture groups in a regex?

Use the (?<name>pattern) syntax to create named capture groups. For example, (?<year>\d{4})-(?<month>\d{2}) captures year and month separately. The tester displays each group's name and matched value in the Matches panel, making it easy to verify complex extraction patterns.