To improve the manufacturing economy and design rationality of the blowout prevention valve of a largescale single ram, we optimize its structural topology. First, we propose the requirements for the topological optimization through analyzing its working principles and characteristics. Second, we establish the flow chart and objective function of the topological optimization and perform the objective function sensitivity analysis. Finally we optimize the structural topology of an actual blowout prevention valve, and the real example shows that our method is effective. The topological optimization results show that the optimized blowout prevention valve can save 16.8% of the material needed for manufacturing and enhance its mechanics characteristics.