In this study, a highly effective flame retardant agent, called polybicyclopentaerythritol phosphate-O-4-imino-p-phenylmethane-4-imino-2-chloro-1,3,5-s-triazine (PEDMCD), has been prepared through a direct polycondensation reaction. PEDMCD was incorporated into epoxy resin (EP) to improve the flame retardancy of EP. The molecular structure and thermal stability of PEDMCD were analyzed by nuclear magnetic resonance spectroscopy. Further, the structural properties, composition, and thermal stability of the PEDMCD/EP composite were characterized by Fourier transform infrared (FTIR) spectroscopy and thermogravimetric analysis (TGA). PEDMCD exhibited both high thermal stability and high flame-retardant performance; these properties were attributed to the phosphorus-containing structure on the side groups and a triazine structure as the molecular backbone, which played the role of a foaming carbon source. With the addition of PEDMCD, the flame-retardant behavior of PEDMCD/EP composites was gradually enhanced. Furthermore, the amount of char residue of the PEDMCD/EP composite at 500 °C was increased from 21% to 34%. The peak value of the mass loss rate of PEDMCD/EP decreased from 0.52 to 0.35 g s−1. Further, the TSP of the sample decreased from 44.2 m2 to 24.6 m2, and the total oxygen consumption decreased from 64.2 g to 30.4 g. Accordingly, owing to the incorporation of PEDMCD, EP begins to decompose sooner, and the carbon layer formed by decomposition reduces the decomposition rate of the EP matrix. Based on the results of characterization measurements and flame retardancy testing, it is confirmed that PEDMCD exhibits good flame retardancy when applied in EP.