Flame-retardant vinyl ester resins (VER) have long been studied, however, very few flame retardants can efficiently improve the flame retardancy of the resin without deteriorating their other performance. In this work, a kind of liquid phosphorus-containing 1-vinylimidazole salt (called VC) was synthesized in a facile way with a very high yield. Then, VC was used as the flame-retardant crosslinking agent to obtain flame-retardant VER. Curing behaviors, flame retardancy, thermal stability, thermomechanical properties, and mechanical performance of the resin were investigated. VC had good compatibility with VER and the mixture presented a relatively low viscosity. VC/VER showed a high curing activity and can be efficiently cured in moderate conditions. VC was incorporated into the resin mainly by ionic bonds, by which interchain ionic interactions were constructed in the resin. With only 15 wt% additions of VC, the cured VC15/VER easily passed the UL 94 V0 rating and achieved a limiting oxygen index value of 32.7%. In the cone calorimetric test, VC15/VER severally presented a reduction in the peak heat release rate, total heat release rate, and total smoke release rate of 67.8%, 17.1%, and 27.3% compared to VER. VC15/VER showed good thermal stability, had a glass transition temperature of 151 °C (that of VER was 137 °C), and achieved high mechanical performance that can be comparable to VER. Hence, this work proposes a facile strategy for producing flame-retardant thermosets with well-balanced comprehensive performance, which exhibits potential in coatings, composites, and laminates for versatile applications.