Skip to content
Devtoolry

Regex Tester

Test JavaScript regular expressions with live match highlighting, capture groups and flags.

About the Regex Tester

The Regex Tester runs JavaScript regular expressions against your text as you type, highlights every match and lists capture groups, so you can build a pattern step by step instead of guessing.

Everything runs in your browser, so your input is never uploaded to a server.

How to use the Regex Tester

  1. Type the pattern between the slashes and toggle flags: global, ignore case, multiline, dot-all and Unicode.
  2. Paste the text to search in the test string box.
  3. Read the highlighted matches and capture groups, then copy the finished pattern.

Frequently asked questions

Which regex flavour does it use?

JavaScript (ECMAScript), the same engine as browsers and Node.js. Most syntax is shared with PCRE, but some features such as possessive quantifiers are not supported.

Can a pattern freeze the page?

No. Matching runs in a background worker with a time limit, so catastrophic backtracking is stopped instead of hanging your browser.