DevKnife

Home › Regex tester

Regex tester

Test regular expressions live: highlighted matches, capture groups, flags and replace preview. JavaScript regex engine, runs locally.

🔒 Runs 100% in your browser — safe for real data

Matches

How to use the regex tester

  1. Enter your regular expression and pick flags.
  2. Paste a test string — matches highlight live.
  3. Optionally enter a replacement to preview the result.

About this tool

Type a pattern and test string to see every match highlighted, with indexes and capture groups listed in a table. Toggle flags: g global, i ignore case, m multiline anchors, s dot matches newline, u Unicode. The replace box previews String.replace output using $1-style references.

Cheat sheet

FAQ

Is my data sent to a server?

No. DevKnife tools run entirely in your browser with JavaScript. Nothing you paste — API keys, tokens, customer data — is transmitted or logged, so it is safe for production data.

Which regex flavor is this?

JavaScript (ECMAScript). It is very close to PCRE for common patterns; lookbehind and named groups are supported in modern browsers.

Related tools