Email Regex Example
Validate common email-like strings with a practical pattern suitable for frontend form checks.
This email regex example matches typical mailbox@domain addresses used in application forms. It allows letters, digits, dots, underscores, plus signs, and dashes in the local part, then requires an @ symbol, a domain label, and a top-level domain of at least two letters. It is useful for client-side pre-validation where you want to catch obvious input mistakes before submitting data to your backend. Like most email regex patterns, this is intentionally practical rather than fully RFC-complete, because full compliance can be complex and often unnecessary for standard web forms. For production systems, treat this as an early format check and run authoritative validation server-side as well. You can open this pattern directly in the Regex Tester workspace, test against your own sample list, then refine it for your exact product rules.
Pattern
/^[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,}$/iMatches
dev.team@example.com
alex+alerts@company.io
user_123@test.co
Rejects
plainaddress
missing-at.example.com
admin@localhost
FAQ
Is this email regex fully RFC compliant?
No. It is a practical validation pattern for common addresses, not a full RFC parser.
Should email validation still happen server-side?
Yes. Client-side regex should be an early check, while backend validation remains the source of truth.
Can I allow internal domains without TLD?
Yes. Adjust the domain section if your workflow accepts internal-only addresses such as admin@intranet.
Related: Regex Tester & Generator, Text Diff Checker, JSON vs YAML guide.
Browse all patterns in the regex examples hub.
More regex examples
Phone Number Regex Example - Match normalized phone numbers with optional plus prefix and 7 to 15 digits.
Password Regex Example - Require uppercase, lowercase, number, symbol, and a minimum length for strong-password policies.
URL Regex Example - Validate common HTTP/HTTPS URLs including optional ports, paths, and query fragments.
IPv4 Regex Example - Match IPv4 addresses with strict 0-255 octet validation for each of four segments.