Regex Tester

Try a regular expression pattern against your own text and see every match highlighted.

The Regex Tester applies a regular expression to a piece of text and shows every match, using the browser's native regular expression engine.

Your files are processed locally in your browser and are not uploaded.

How to use Regex Tester

  1. 1

    Enter the pattern

    The regular expression.

  2. 2

    Enter flags

    Optional — matching all occurrences is already applied automatically.

  3. 3

    Paste the test text

  4. 4

    See the matches found

Testing before using it in code

Writing a regular expression directly in code makes every tweak slower — you have to save, run and check the result each time. Testing the pattern on its own, against real sample text, makes that loop much faster.

When should you use this tool?

  • Developers

    Validate a regex pattern before using it in code.

  • Data extraction

    Check whether a pattern correctly matches the desired parts of a text.

  • Form validation

    Test a validation rule (email, zip code, phone) against real examples.

Frequently asked questions

Which regex flavor does this use?
It uses your browser's native JavaScript regular expression engine.