Regex Tester
Test regular expressions in real time. Match, replace, or split text with flexible flags.
Matches: 0Pattern: /\b[A-Z][a-z]+\b/g
Enter a regex and test string to see matches highlighted here.
How to Use This Tool
- Open the Regex Tester and provide the inputs requested in the form above.
- The Regex Tester processes your input directly in your browser and shows the result on the same page.
- Copy or save the output, then adjust the inputs anytime to see an updated result.
Common Use Cases
- Form validation: Frontend developers test email and phone patterns against real-world input edge cases before deploying to production.
- Log parsing: SREs build regexes to extract IP addresses, timestamps, or error codes from multi-line application logs.
- Code refactoring: Engineers craft search-and-replace patterns for VS Code or sed/awk pipelines, verifying captures before running against a large repo.
Frequently Asked Questions
What's the difference between greedy and lazy quantifiers?
How do I match an email address with regex?
RFC 5322 allows characters that practical regexes ignore. A safe pattern is ^[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,}$. For full validation, send a confirmation email; regex alone cannot verify deliverability or catch all edge cases like quoted local parts.
Does this tester support PCRE features like lookbehind?
The tester uses the browser's JavaScript regex engine (ECMAScript 2018+), which supports lookbehind ((?<=...)), named groups ((?...)), and Unicode property escapes (\p{L}). PCRE-only features like recursion and possessive quantifiers are not supported.