Regex Tester

Test regular expressions with live match highlighting, groups and replace — safely, with a timeout.

Runs instantly in your browser — results update as you type.

What is a regex tester?

A regex tester lets you write a regular expression and immediately see which parts of a sample text it matches, including capture groups, so you can build and debug patterns before using them in code.

How to use the Regex Tester

    Frequently asked questions

    Which regex flavour is used?

    JavaScript (ECMAScript). Syntax is very close to PCRE, but lookbehind support and some flags differ in other languages.

    Why was my regex stopped?

    It ran for more than 2 seconds, usually because of nested quantifiers like (a+)+ that cause catastrophic backtracking.

    Do I include the slashes?

    No. Enter only the pattern and choose flags with the checkboxes.