using System; using System.Text.RegularExpressions; public class Test { public static void Main() { string email = "an.email@ahost.com"; string regex = @"^([\w-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([\w-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$"; Regex rgx = new Regex(regex); Boolean result = rgx.IsMatch(email); System.Console.WriteLine("{0} validation is {1}", email, result.ToString()); } }