Regex Tester

Test regular expressions with real-time highlighting and capture group details.

//g
Matches will be highlighted here...

What is a Regex Tester?

A regex tester is a tool that lets you write a regular expression pattern and test it against sample text to see which parts match. It's essential for developers working with string parsing, validation, and text processing.

How to use this tool

  1. Type your regular expression in the pattern field.
  2. Toggle flags (g, i, m, s, u) as needed.
  3. Paste test text in the left textarea.
  4. Matches are highlighted on the right in real-time.
  5. Scroll down to see match positions and capture groups.

Common Regex Examples

\d+

Matches one or more digits (e.g., "123", "42").

[a-zA-Z]+

Matches one or more letters.

\b\w+@\w+\.\w+\b

Matches basic email addresses.

^\s*$

Matches empty or whitespace-only lines.

Privacy

Your pattern and test text are processed entirely in your browser. Nothing is uploaded to any server.

Frequently Asked Questions

Is this Regex Tester free?

Yes, completely free. No signup, no limits.

Is my data uploaded to a server?

No. All matching happens in your browser using JavaScript's RegExp engine. Your text and pattern never leave your device.

Which regex flavor does it use?

It uses JavaScript's native RegExp engine, which is based on ECMAScript. Most patterns from other languages (Python, PCRE) work, but some advanced features may differ.

What do the flags mean?

g = global (find all matches), i = ignore case, m = multiline, s = dotall (dot matches newlines), u = unicode.

Can I use capture groups?

Yes. Parentheses () create capture groups, and they'll be shown in the match details below the output.

Related Tools