Regex Tester & Visualizer
Test a pattern against sample text with live highlighting, a full match list, and capture groups.
| # | Match | Index | Groups |
|---|---|---|---|
| 1 | hello@calcuforge.com | 14 | — |
| 2 | support@example.com. | 38 | — |
Common pattern building blocks
Extracting email addresses from text
The default pattern loaded in the widget, [\w.+-]+@[\w-]+\.[\w.-]+, matches a typical email address: one or more word characters, dots, plusses, or hyphens before the @, a domain name, and a dot-separated extension. Against the sample test string it finds both email addresses and highlights them directly in the text, while leaving the phone number and order ID untouched.
| Pattern piece | Matches |
|---|---|
| [\w.+-]+ | The local part before @ |
| [\w-]+ | The domain name |
| \.[\w.-]+ | The dot and extension |
Common questions
This tool runs your pattern through JavaScript's native RegExp engine — the same one used in browsers and Node.js. Most core syntax (character classes, quantifiers, groups, lookahead) is shared across regex flavors, but some features differ from PCRE (used by PHP, many text editors) or Python's re module, so a pattern that works here should be spot-checked if you're deploying it in a different language.