Regex Tester

Type a pattern and a text — matches are highlighted in real time.

How to use it

Type a regular expression pattern in the first field, the flags you want (g, i, m, s...) in the second, and the text to search in the third. Matching parts are highlighted in yellow automatically, with no button to click.

Most common flags

g (global — finds every match, not just the first), i (case-insensitive), m (multiline — ^ and $ match per line), s (lets . match line breaks too).

Frequently asked questions

Which regex "flavor" does this tool use?

JavaScript's own regular expression engine (ECMAScript) — the same one used in browsers and Node.js.

Is my text sent to any server?

No — everything runs locally in your browser, in JavaScript.

Why doesn't my pattern match anything?

Check whether special regex characters (like . * + ? ( ) [ ] {} ^ $ |) you want to use literally are escaped with a backslash.