Test Your Regular Expression
/
/
Enter the pattern without leading/trailing slashes. Use standard JavaScript regex syntax.
Matches will be highlighted in the text above or listed here.
Match Count: 0
How to Use
- Enter your regular expression pattern in the "Regular Expression" field (without the surrounding `/` characters).
- Optionally, enter any flags (like `g` for global, `i` for case-insensitive) in the small flags field.
- Paste or type the text you want to test against in the "Test String" area.
- Matches will be highlighted in the test string area automatically as you type the regex or test string.
- The total match count is displayed below the output area.
Tip: Use the global flag (`g`) to find all matches, not just the first one.
Why Use a Regex Tester?
- Develop Regex Patterns: Interactively build and test regular expressions.
- Debug Regex: Understand why a pattern isn't matching as expected.
- Learn Regex Syntax: Experiment with different patterns and flags.
- Validate Input: Test patterns used for form validation or data parsing.