Regex Tester
Test regular expressions with live match highlighting and capture group inspection. Toggle flags, see matches update as you type.
Matches
How to use
- Type your pattern in the top field — no surrounding slashes needed. Special characters like \d, \w and + work directly.
- Toggle the flags you need: g for all matches, i for case-insensitive, m for per-line ^ $, s so the dot matches newlines, u for full Unicode.
- Paste sample text on the left. The right pane highlights every match instantly, and the list below shows each match with its capture groups.
Frequently asked questions
What do the regex flags g, i, m, s and u mean?
g means global (find all matches, not just the first). i means case-insensitive. m makes ^ and $ match the start and end of each line instead of the whole string. s allows the dot to match newlines. u enables full Unicode support, including code points above U+FFFF.
Is it safe to paste sensitive text into this regex tester?
Yes. This tool runs entirely in your browser using JavaScript. Nothing you type is ever sent to a server — you can verify this by opening your browser's network tab while using it.
Which regex flavor does this tester support?
It uses the JavaScript regex engine built into your browser (ECMAScript 2024+). This covers the vast majority of everyday patterns. Features from other flavors like lookbehind and named groups are supported in all modern browsers; recursion and possessive quantifiers are not part of the JavaScript flavor.
Why does my regex highlight only the first match?
The global flag g is most likely off. Enable it to highlight every match in the text. Without g, JavaScript regular expressions stop after the first match by design.