The invention discloses a preparation method of poly (diallyldimethylammonium chloride) as flocculating agent for treating sewage. The preparation method comprises the following steps: (1) adding an initiator, a complexing agent and ethylene glycol as a chain transfer agent in an aqueous solution of diallyldimethylammonium chloride, stirring uniformly, and feeding nitrogen to remove air in a reaction container; (2) heating reaction liquid obtained from the step (1) while stirring, and carrying out polymerization reaction; (3) heating to the temperature of 65-85 DEG C, adding the initiator in the reaction liquid again, and adding water in the reaction liquid for reaction; and (4) under protection of the nitrogen, carrying out insulation and curing to obtain the poly (diallyldimethylammonium chloride). The method is simple in process and easy to operate, the reaction temperature is convenient to control, polymerization reaction is stably carried out at low speed, products with medium and low relative molecular mass are easily obtained, and the preparation method is suitable for treatment of oilfield chemical flooding output liquid. The prepared flocculating agent for treating the sewage is high in oil removal rate, high in monomer conversion rate, good in water purification effect, low in viscosity of products and convenient to inject, and has universal applicability.