The invention relates to a propargyl alcohol type quaternary ammonium salt surfactant and a preparation method thereof, and the structural formula of quaternary ammonium salt is as follows: n is equal to 8, 10, 12, 14 or 16, and X is Cl or Br; and a substituent is positioned in the ortho-position, interposition or para-position. The preparation method is as follows: (1) adding 3-5g of NaH into a reactor, introducing nitrogen, adding 60-90ml of THF (tetrahydrofuran), stirring at room temperature, dropping 4-6g of propiolic alcohol, further slowly dropping 10-15g of chloromethylpyridine, stirring for 15-30h, separating water phase from organic phase, washing, drying, performing column chromatography, and then getting pyridyl-2-butynol; and (2) adding the pyridyl-2-butynol and alkyl halide into the reactor according to the molar ratio of 1: 1.5-1: 4, further adding 10ml-15ml of acetonitrile, refluxing and stirring for 20-30h at the temperature of 50-80 DEG C, washing, performing the column chromatography, and then getting the alkynol type quaternary ammonium salt surfactant. The series of the propargyl alcohol type quaternary ammonium salt surfactants have very high surface activity and very strong corrosion inhibition performance, the preparation method is simple and feasible, the operation is easy, the yield is higher, and the environmental pollution can be avoided.