Home/Regex Tools/Regex tester & explainer

Regex tester & explainer

Regex Tester and Explanation Tool

JavaScript regular expressions only. Everything runs locally in your browser.

0 matches Valid regex
PatternNo slashes needed (enter the pattern only)

Performance (estimate)

Run time

Text

106 chars

Matches

0

Flags

giu

Enter a valid pattern and some text to measure.

FlagsToggle options

Active: giu

Tip: use g to see all matches; remove it to see just the first.

Test textPaste data or type freely
Highlighted matchesVisual preview
Contact: hello@example.com Support: support@stackatlas.dev Invalid: not-an-email@ Upper: Admin@Example.COM
MatchesIncludes capture groups
No matches found.

Max 500 matches rendered to keep things fast.

Regex explanationHuman-readable breakdown

Finds all matches. Looks for a match inside the input using JavaScript regex.

gGlobaliIgnore caseuUnicode

Breakdown

(?<user>
Named capturing group “user”.
[a-z0-9._%+-]
Character class (match one char from the set).
+
Repeat 1 or more times.
)
End of group.
@
Literal character.
(?<domain>
Named capturing group “domain”.
[a-z0-9.-]
Character class (match one char from the set).
+
Repeat 1 or more times.
\.
Escaped literal “.”.
[a-z]
Character class (match one char from the set).
{2,}
Exactly 2 times.
)
End of group.

Quick tips

  • Use ^ and $ to validate the whole string.
  • Turn on g to see every match in the text.
  • Prefer [\\s\\S] if you need “any character” without relying on dotAll.

Common recipes

  • \\d+ — one or more digits
  • \\b\\w+\\b — whole words
  • ^\\S+$ — non-empty, no spaces
  • ^(a+)+$ — slow example (backtracking)

Privacy & engine

This tool runs entirely in your browser using the JavaScript regex engine. Your text and patterns are not sent to a server.

If you’re comparing against PCRE/.NET/RE2, behavior can differ (especially around lookbehinds, Unicode, and backtracking).