Regex to Match Email Addresses (With Examples)
The best regex patterns for matching email addresses: simple validation, RFC-compliant, and production-ready patterns with tests.
Simple Email Regex
[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}This catches 99.9% of valid emails. Test it in our Regex Tester.
What It Matches
- user@example.com ✓
- first.last+tag@company.co.uk ✓
- user@.com ✗
- @example.com ✗
Why Not RFC 5322 Compliant?
The full RFC allows quoted strings, comments, and IP addresses as domains. A fully compliant regex is thousands of characters long and impractical. For production, combine a simple regex with an actual email verification (send a confirmation).
Try It Free
Use our free online tool — 100% client-side, no data leaves your browser.
Open Regex Tester