Regex Tester

Test your regular expressions against sample text.

//

Matches (2)

Match 1Index: 0
hello
Groups:Group 1: hello
Match 2Index: 6
world
Groups:Group 1: world

How to use

Enter your pattern, set any flags you need (like 'g' for global or 'i' for case-insensitive), and type or paste your test text. Matches update live, with each match's index and any capture groups listed below it.

  • Enter your input in the text area provided.
  • Adjust any settings or options if available.
  • The results will be generated automatically or upon clicking the action button.
  • Copy the result to your clipboard using the copy button.
Advertisement
AdSense Placeholder

About Regex Tester

Regex Tester runs a regular expression against sample text and shows every match live as you type, including any capture groups within each match.

Common Use Cases

  • Debugging why a regex isn't matching what you expect before using it in code.
  • Testing an email, URL, or phone-number pattern against a range of sample inputs.
  • Understanding what a capture group in an existing regex actually extracts.

Tips

The 'g' (global) flag changes whether the tool finds every match or stops at the first one — if you're only seeing one result but expect more, check whether 'g' is included in the flags field.

Related Tools