No upload to server Fast Free

Regex Tester Online

Test regular expressions with live highlighting, capture groups, flags and replace preview. Private by design: everything runs in your browser.

//g
Flags:
2 matches

Matches highlight in yellow as you type. The caret stays visible while editing.

Match list

  1. #1hello@toolsofweb.comat 14–34
    $1 = hello$2 = toolsofweb.com
  2. #2support@example.orgat 38–57
    $1 = support$2 = example.org

Related guide

Read guide: regex tester (flags, capture groups, debugging patterns) →

Test regular expressions (free, no signup)

Regular expressions are powerful but unforgiving — one misplaced bracket and the pattern silently matches nothing. This free regex tester shows you exactly what your pattern does: matches light up in your test text as you type, the match list breaks out every capture group with its position, and invalid patterns get a plain-English error instead of a silent failure.

It runs JavaScript’s RegExp engine, so what you see here is what you get in the browser or Node.js. Toggle flags to compare behavior — g for all matches, i to ignore case, m for line-by-line ^…$ anchors — and flip to Replace mode to preview substitutions with $1, $2 back-references before you commit them to code.

Common use cases

  • Debug why a validation pattern rejects real input
  • Build email, URL, or phone-number patterns interactively
  • Preview find-and-replace across pasted text or logs
  • Learn regex with the built-in cheatsheet and live feedback

Cleaning up the text you matched? Run it through ToolsOfWeb’s Text Cleaner to normalize whitespace, or compare two versions with the Text Diff Checker.

FAQs

What does a regex tester do?+

A regex tester lets you try a regular expression against your own text and see every match instantly — highlighted in the text, listed with capture groups, and with errors explained. It is the fastest way to build and debug patterns without running code.

Is my pattern or test text uploaded anywhere?+

No. Testing runs entirely in your browser using JavaScript’s built-in RegExp engine. Nothing you type ever leaves your device.

Which regex flavor does this tester use?+

JavaScript (ECMAScript) regular expressions — the same engine that runs in your browser and in Node.js. Most syntax transfers directly to Python, Java, and other languages, though some advanced features differ by flavor.

What do the g, i, m, s, u, y flags mean?+

g finds all matches instead of stopping at the first; i ignores case; m makes ^ and $ match line boundaries; s lets . match newlines; u enables full Unicode mode; y (sticky) matches only from the current position. Toggle them above the test box to see the difference live.

Why does my regex show an error?+

Usually an unbalanced bracket or parenthesis — for example [a-z without the closing ]. The tester shows JavaScript’s exact error message, which normally points at the problem character.

More free tools

Want guides and tips? Visit the ToolsOfWeb blog or go back to the homepage.

Related guide

Read guide: regex tester (flags, capture groups, debugging patterns) →