Regex Tester

Test regular expressions in real time with match highlighting and capture group details.

/ /

Free Online Regex Tester

The Toolts Regex Tester lets you write and test regular expressions against sample text in real time. Matches are highlighted with alternating colors, and capture group details are shown in a table below. The tool supports JavaScript regex syntax with global (g), case-insensitive (i), multiline (m), and dotAll (s) flags.

How to Use

Enter your regular expression pattern in the top field, type or paste your test string in the textarea, and see matches highlighted instantly as you type. The match table below shows each match with its capture groups, index position, and full match text. Common patterns include email validation, URL parsing, phone number extraction, and data cleanup.

JavaScript Regex Flags

The g (global) flag finds all matches rather than stopping after the first. The i flag makes the pattern case-insensitive. The m (multiline) flag makes ^ and $ match the start and end of each line rather than the entire string. The s (dotAll) flag makes the dot (.) match newline characters as well.