Testador de expressões regulares
Teste expressões regulares em um texto de exemplo com destaque de correspondências em tempo real.
What is a Testador de expressões regulares?
Regular expressions are notoriously easy to get subtly wrong — an unescaped special character, a greedy quantifier matching more than intended — and a live tester that highlights matches against real sample text as you type catches those mistakes far faster than trial-and-error inside your actual codebase.
How to use the Testador de expressões regulares
- Enter a pattern and flags
- Paste sample text
- Matches are highlighted live, on your device
Example
The pattern \b\w+@\w+\.\w+\b against the text "contact us at hi@example.com or admin@test.org" highlights both hi@example.com and admin@test.org as matches, live, as you edit either the pattern or the text.
Frequently asked questions
Is my data uploaded anywhere?
No — Testador de expressões regulares runs entirely in your browser using JavaScript/WebAssembly. Your data is never sent to a server.
What regex flavor does this use — is it the same as Python or PCRE?
This uses JavaScript's native RegExp engine, so syntax matches what you'd write in a browser or Node.js. Most common patterns are portable to other flavors, but some features, like Python's named-group syntax, differ slightly.
Why isn't my pattern matching anything, even though it looks correct?
Check the flags first — a case-sensitive pattern (no \"i\" flag) won't match different-case text, and without the global \"g\" flag only the first match is found rather than all of them.