Regex Tester
Write a regular expression and see every match, capture group and replacement live.
Matches: 2
Contact alex@example.com or sales@giis.ai for details.
Not an email: hello@ or @world
#1 at 8: "alex@example.com" · $1="alex" · $2="example.com" · user="alex" · domain="example.com"
#2 at 28: "sales@giis.ai" · $1="sales" · $2="giis.ai" · user="sales" · domain="giis.ai"
Regex cheat sheet
\ddigit,\wletter/digit/underscore,\swhitespace,.any character*0 or more,+1 or more,?optional,{2,5}between 2 and 5^start,$end,\bword boundary(…)capture group,(?:…)non-capturing,(?<name>…)named group(?=…)lookahead,(?<=…)lookbehind,[^…]any character except
Frequently asked questions
Which regex flavour does this use?
JavaScript (ECMAScript) regular expressions, the same engine as Node.js and every browser. Most syntax also works in Python, Java and PCRE, but lookbehind, named groups and some escapes differ slightly between languages.
How do I see capture groups?
Each match is listed with its numbered groups ($1, $2 …) and any named groups, such as (?<year>\d{4}).
What do the flags do?
g finds every match instead of the first, i ignores case, m makes ^ and $ match at line breaks, s lets . match newlines, and u enables full Unicode matching.
Is my text uploaded?
No. The regex runs in your browser.
Related free tools
JSON formatter · SQL formatter · Diff checker · Case converter