string _email = "294243780@qq.com"; Regex Rzz = new Regex(@"(.{2}).+(.{2}@.+)", RegexOptions.IgnoreCase | RegexOptions.Singleline | RegexOptions.IgnorePatternWhitespace); _email = Rzz.Replace(_email, "$1****$2", 1); Response.Write(_email);