Skip to main content
{/}codefunc

Regex Tester

Test regular expressions against sample text.

About this tool

Run JavaScript regular expressions against sample text with live match highlighting. Tune patterns for validation rules, log parsing, or search-and-replace planning before touching production code.

Global, case-insensitive, and multiline flags are supported. Results update as you type. For catastrophic backtracking and frontend debugging patterns, see the regex guide on the blog.

Test strings stay in your browser — nothing is uploaded.

How to use

  1. Enter the regular expression pattern (without surrounding slashes).
  2. Add flags such as i or m as needed — global matching is handled by the tester.
  3. Paste sample text and inspect matches, groups, and failures.
  4. Iterate until edge cases (empty strings, unicode, newlines) behave as intended.

Example

Match a short ID fragment

Input

pattern: \d{3}-\d{2}
text: ID: 123-45

Output

matches: ["123-45"]

Limitations

  • Uses JavaScript RegExp semantics — not PCRE, .NET, or Python re flavor parity.
  • Catastrophic backtracking patterns can hang the tab; keep test strings short while drafting.
  • Does not replace a full debugger for lookbehind/unicode property edge cases across engines.

Related guides

1

Related tools

1

Frequently asked questions

What does the Regex Tester do?

Test regular expressions against sample text. Runs in your browser — no install, no account.

How do I use the Regex Tester?

Enter the regular expression pattern (without surrounding slashes). Add flags such as i or m as needed — global matching is handled by the tester. Paste sample text and inspect matches, groups, and failures. Iterate until edge cases (empty strings, unicode, newlines) behave as intended.

Is the Regex Tester free?

Yes. No signup, no usage limits, no paywall.

Does the Regex Tester upload my data?

No. Processing happens locally in JavaScript. Your input is not uploaded, stored, or logged.

What are the limitations of the Regex Tester?

Uses JavaScript RegExp semantics — not PCRE, .NET, or Python re flavor parity. Catastrophic backtracking patterns can hang the tab; keep test strings short while drafting. Does not replace a full debugger for lookbehind/unicode property edge cases across engines.

Search tools

Find a developer tool