๐Ÿ”Ž

Regular Expression Tester

Test regular expressions with live highlighting

//
Enter a regex pattern and test string to see matches

How to Use

  1. 1

    Enter your regular expression in the pattern field at the top. Use the flag checkboxes to toggle global (g), case-insensitive (i), multiline (m), and other flags.

  2. 2

    Type or paste your test string in the input box below. Matches are highlighted in real time.

  3. 3

    Review the match details panel to see each match, its position, and any captured groups.

Frequently Asked Questions

What regex flavors are supported? โ–ผ
This tool uses JavaScript regular expressions, which support flags: global (g) for all matches, case-insensitive (i), multiline (m) to treat ^ and $ as line boundaries, dotall (s) to make . match newlines, and unicode (u) for full Unicode support.
Does this tool support named capture groups? โ–ผ
Yes. JavaScript named capture groups using the (?<name>...) syntax are fully supported and their values are displayed in the match details panel.
How do I match across multiple lines? โ–ผ
Use the multiline flag (m) to make ^ and $ match the start and end of each line instead of the entire string. Use the dotall flag (s) to make the . character match newline characters as well as everything else.
What is a capture group? โ–ผ
Capture groups let you extract specific parts of a match. Use parentheses: (\d+) captures one or more digits. Named groups use (?<name>\d+) syntax for clearer references. Non-capturing groups use (?:...) when you want to group without capturing.