Write a regular expression and see it match your text in real time — with color-coded capture groups, a plain-English explanation of what your pattern does, find & replace, and a library of common patterns. It runs on the JavaScript engine, entirely in your browser. Free, no sign-up.
A regex (regular expression) tester lets you build and debug a pattern against sample text and instantly see what it matches. Instead of guessing, you get live highlighting, group breakdowns and errors as you type — which turns regex from trial-and-error into something you can actually reason about. This one also explains your pattern token by token.
Which regex flavor does this use?
The JavaScript (ECMAScript) engine — the same one in browsers and Node.js. Most syntax is shared with other flavors; a few features follow JavaScript's specific rules.
Is my regex and test text private?
Yes. Matching runs entirely in your browser — nothing is sent to a server, so you can safely test against sensitive sample data. It works offline too.
What do the flags g, i, m, s mean?
g global (all matches), i case-insensitive, m multiline (^/$ per line), s dotall (. matches newlines). Toggle them in the tester.
What is a capture group?
A part of the pattern in parentheses, like (\d{4}), that extracts a sub-match. The tester color-codes each group so you can see exactly what it captured.
Greedy vs lazy matching?
Greedy quantifiers (.*) match as much as possible; lazy ones (.*?) match as little as possible — useful for the shortest match, like text between two tags.