URSY.IOPART OF THE URSY NETWORKSign in400 free tools

Developer Tools

Regular Expression Tester

Test a JavaScript regular expression against sample text and inspect matches.

Free No account Runs on this device
Developer Tools
Tool ready

Your inputs stay in this browser tab.

Powering up the tool…

TOOL REGEX-TESTER

What this tool does

About the regular expression tester

The tool highlights capture groups, indexes and replacements using the browser JavaScript engine. It limits runaway work and identifies invalid flags.

How to use it

  1. Enter the pattern and flags — invalid flags are named, not swallowed.
  2. Paste sample text that includes the cases you fear, not just the happy path.
  3. Inspect the highlighted matches, group captures and indexes.
  4. Try a replacement string to preview substitutions with group references.

Useful for

  • Build a pattern against real sample text instead of deploying and praying.
  • See exactly what each capture group grabs before the pattern goes in code.
  • Debug why a regex matches too much, too little or nothing at all.

Straight answers

Regular Expression Tester FAQ

Will this pattern behave the same in Python or PHP?

Mostly, but not always: this tester runs your browser’s JavaScript engine, and flavours differ on lookbehind details, named groups and escapes. Test in the destination language before shipping anything clever.

Why does my pattern freeze other testers but not this one?

Catastrophic backtracking — nested quantifiers exploding on non-matching input. This tool bounds runaway work so you discover the problem as a fast failure here rather than a hung process in production.