Skip to content
Schedule a Call

Test a regular expression

Test regular expressions with live match highlighting, capture groups, flags and a quick-reference cheat sheet. JavaScript regex, free and private.

  • Files never leave your device
  • Free, no sign-up
  • No watermark
Loading tool…

About Regex Tester

Write and debug regular expressions with instant feedback. Type a pattern and a test string and every match is highlighted as you type, with capture groups listed separately so you can see exactly what each part of your pattern grabs. Toggle the global, case-insensitive, multiline and other flags, and use the built-in cheat sheet when you forget the syntax. It uses the JavaScript regex engine, the same one your browser and Node.js run.

How to use Regex Tester

  1. 1

    Enter your regex pattern.

  2. 2

    Choose flags such as g, i or m.

  3. 3

    Paste the text to test against.

  4. 4

    Review highlighted matches and capture groups.

Why use this tool

  • Real-time match highlighting.
  • Capture groups shown separately.
  • All JavaScript regex flags.
  • Built-in quick-reference cheat sheet.
  • Sample patterns to start from.

Frequently asked questions

JavaScript (ECMAScript), as used by browsers and Node.js. Most syntax is shared with PCRE, Python and Java.

Add the g flag to find all matches instead of the first.

Use the m flag for ^ and $ per line, and the s flag to let . match newlines.

Parentheses in a pattern capture the matched text so you can reuse it, for example in a replacement.

Yes. Paste sample addresses and adjust the pattern until only valid ones match.

No. Everything is processed in your browser tab. Nothing you type or paste is sent to CodeMites or any other server.

Yes. There is no account, no watermark and no usage limit. The tool runs in your own browser, so there is no server cost to charge you for.

Yes. It runs in any modern browser on Android and iOS as well as on Windows, macOS and Linux, with nothing to install.

Yes, once the page has loaded. Everything runs in your browser, so you can keep working on a train or plane without a connection.