Regex Tester
Write a pattern, paste some text, and watch matches highlight instantly. Inspect numbered and named capture groups, test replacements, and see syntax errors without leaving the page.
Free Runs locally No signup
Contact kotlinamai@example.com or support@amai.tools for help.
matches2
- #1
kotlinamai@example.com@8 - #2
support@amai.tools@34
Result
Contact or for help.
Text is capped at 50,000 characters. Matches update as you type.
How to use it
1
Enter a pattern
Type the expression without the surrounding slashes, then toggle the flags you need.
2
Paste your text
Add the text to test. Matches highlight immediately and are listed with their positions.
3
Inspect or replace
Open the match list to see capture groups, or type a replacement to preview the result.
Why use this tool
Live highlights
Every match is highlighted in the text as you type, so you can see exactly what the pattern captures.
Capture groups
Numbered and named groups are listed for each match, which makes debugging complex patterns faster.
Errors explained
Invalid patterns show the browser error message instead of silently failing.
Frequently asked questions
Which regex flavour is used?
JavaScript regular expressions, the same engine that runs in Node.js and browsers. It supports lookbehind, named groups, Unicode property escapes and the sticky flag.
What do the flags mean?
g finds every match, i ignores case, m makes ^ and $ match line boundaries, s lets the dot match newlines, u enables Unicode mode and y anchors each match at the previous end position.
Why do I only see one match without the g flag?
That is how JavaScript behaves: without g, the first match is returned and scanning stops. Turn on g to list every match.
Can a pattern freeze the page?
Possibly. The tester limits the input size and caps the number of stored matches, but it does not interrupt a pattern that is already running, so avoid nested quantifiers such as (a+)+ on long text.
Is the text I paste uploaded?
No. The pattern and the text stay in your browser, and nothing is logged or sent to a server.
Related tools
Text Tools Diff Checker Compare two texts and highlight added, removed and unchanged lines, words or characters. Runs locally in your browser with no upload. Text Tools Case Converter Convert text between UPPER CASE, lower case, Title Case, sentence case, camelCase, PascalCase, snake_case and kebab-case instantly. Developer Tools JSON Formatter & Validator Format, validate and minify JSON in your browser. Choose 2 or 4-space indentation, sort keys, and copy the result instantly. Free, private, no signup. Developer Tools URL Encoder & Decoder Encode or decode URLs and query strings with correct UTF-8 percent encoding. Switch between component and full-URL modes, all in your browser. Developer Tools Base64 Encoder & Decoder Encode text to Base64 or decode Base64 back to text, with full UTF-8 and URL-safe support. Runs locally in your browser — no upload, no signup. Developer Tools Hash Generator Generate MD5, SHA-1, SHA-256, SHA-384 and SHA-512 hashes from text in your browser. Compare digests and copy them instantly.
Last updated: