Regex Tester
Test regular expressions with live match highlighting, explanations, saved patterns, and a built-in cheat sheet.
No saved patterns yet.
About the Regex Tester
A free, browser-based regular expression tester with real-time match highlighting, group capture details, pattern explanations, a built-in cheat sheet, and saved patterns via localStorage. Nothing leaves your browser.
Every match is highlighted as you type, with index positions and capture groups shown inline.
Each token in your regex is broken down with a plain-English description so you can debug faster.
Save patterns you use regularly to localStorage. They persist across browser sessions.
One-click presets for common patterns: email, URL, IPv4, UUID, JWT, semver, dates, and more.
About the Regex Tester
Regular expressions are a powerful pattern-matching language for searching, validating and extracting text. Bytewrench's regex tester lets you write a pattern, set flags, and see live matches highlighted against your sample text — with capture groups broken out so you can build and debug expressions quickly.
It uses the JavaScript regex engine, so what you test here behaves exactly as it will in your JavaScript and TypeScript code.
See every match highlighted in your test string the moment you edit the pattern.
Inspect numbered and named capture groups for each match.
Toggle global, case-insensitive, multiline and other flags interactively.
Patterns and test data stay in your browser.
Frequently asked questions
Which regex flavour does this use?
It uses the JavaScript (ECMAScript) regular-expression engine, so results match how regex behaves in browsers and Node.js.
What do the flags mean?
g matches all occurrences, i ignores case, m makes ^ and $ match line boundaries, s lets the dot match newlines, and u enables full Unicode support.
How do capture groups work?
Parentheses create capture groups whose matched text you can reference. Use (?<name>...) for named groups, which appear alongside numbered groups in the results.
Is my test data private?
Yes. The pattern and sample text are processed entirely in your browser.