In order to satisfy the application of epoxy resin (EP) in high-end electronic packaging, phosphorus fluorine containing polymers were synthesized to simultaneously enhance the flame retardant, dielectric, and hydrophobic properties of EP. Through the reaction of 2-hydroxyethyl methacrylate and 9,10-dihydro-9-oxa-10-phosphaphenanthrene-10-oxide (DOPO), a monomer named HEMA-P was synthesized. By copolymerizing (2,2,2-trifluoroethyl methacrylate and 1H, 1H, 7H-dodecafluoroheptyl methacrylate) with HEMA-P through the typical reversible addition-fragmentation chain transfer (RAFT) polymerization, two phosphorus fluorine containing polymer modifiers named 3FOP and 12FOP with different lengths of fluorine side chain were obtained. The flame-retardant level of FOP/EP composites reached V-1 level. The limited oxygen index (LOI) values of 3FOP/EP and 12FOP/EP composites (10 wt% additive amount) increased to 33.6 ± 0.5 % and 32.8 ± 0.3 %, respectively, with corresponding peak heat release rates (pHRR) decreased by 37.8 % and 33.2 % compared with neat EP, suggesting the FOP modified EP composites have good flame retardant and smoke suppression effects. The mechanical properties of the FOP/EP composites can also be improved. Notably, with the 10 wt% addition of 12FOPs, the water contact angle of 12FOP/EP composite reached 116.5°, which was 40.7 % higher than that of EP. Moreover, the dielectric constant decreased with the increasing fluorine content. The thermal stability and possible thermal degradation pathways of 3FOP and 12FOP were characterized by TG-IR, Py-GC/MS, and Raman spectroscopy. Based on experimental results, we innovatively revealed a phosphorus fluorine synergistic flame retardancy mechanism.