ITInfoByte

Regex Tester

Type a pattern and see matches highlight in your test text as you type, with match positions and capture groups listed below. Uses the JavaScript regex engine — exactly what your browser code will do.

Runs locally — nothing you enter is sent Developer Free · no signup

How to use

  1. Enter a pattern (without the surrounding slashes).
  2. Toggle the flags you need: g (all matches), i (ignore case), m (multiline anchors), s (dot matches newline).
  3. Paste test text — matches highlight live, and the first 20 matches are listed with their positions and capture groups.

Examples

Email-ish pattern
\b[\w.+-]+@[\w-]+\.[\w.]+\b
Capture date parts
(\d{4})-(\d{2})-(\d{2})

Supported formats

  • JavaScript (ECMAScript) regular expression syntax, including lookaheads, lookbehinds, named groups and Unicode escapes.

Privacy

This tool runs entirely in your browser. Nothing you enter or open is sent anywhere. Privacy policy.

Limitations

  • Semantics are JavaScript's — PCRE/Python/Java dialects differ in places (e.g. possessive quantifiers, \A/\z anchors).
  • Catastrophic backtracking patterns on large texts can freeze the tab, as they would in your own code.

FAQ

Why does my pattern match only once?

Without the g flag a regex returns only the first match. Toggle g to find all occurrences — it's on by default here.

Does this support lookbehind?

Yes — all modern-browser JavaScript regex features work, including lookbehind (?<=…), named groups (?<name>…) and Unicode property escapes.

Is my test text sent anywhere?

No. Matching runs in your browser's own regex engine with no network calls — safe for logs and real data.