A novel phosphorus/nitrogen‐containing flame retardant (DOPO‐AM) was synthesized by 9,10‐dihydro‐9‐oxa‐10‐phosphaphenanthrene‐10‐oxide (DOPO) and acrylamide (AM) and its chemical structure was characterized. DOPO‐AM was added into diglycidyl ether of bisphenol‐A (DGEBA) with curing agent m‐xylylenediamine (MXDA)to prepare flame retarded epoxy resin to reduce the possibility of fire. The compounds with different valences sulfur respectively replace partial DGEBA resin to study the effects of sulfur valences on the flame retardance of epoxy resins. The results indicated that DOPO‐AM had excellent flame retardance for epoxy resin. When phosphorus content was only 0.75%, DGEBS resin containing DOPO‐AM achieved the limiting oxygen index value of 34.55% and vertical burning test (UL‐94) V‐0 rating. Although sulfur element is help for refractive index of epoxy resin, sulfur element in three kinds of valences all weaken the flame retardant of epoxy resin. Improving phosphorus content is help for the synergistic effect of PN and PNS. Moreover, the flame retardance is not proportional to sulfur valence, sulfide with +2 valence had the best flame retardance. However, +6 valence sulfonic with strong oxidation effect worsen the flame retardant. Simultaneous thermal analysis of thermogravimetric analyzer and differential scanning calorimeter and scanning electronic microscopy photographs verified the above conclusion.