The invention provides a method for producing high-quality G-class oil well cement with gangue as a siliceous material. The method specifically comprises the following steps that the gangue is used as the siliceous material for dosing, a raw material is obtained through grinding, preheating decomposition, high-temperature calcination and cooling are conducted, so that oil well clinker is obtained, the oil well clinker and gypsum are ground together, and then oil well cement is obtained. After the method is implemented, the raw materials except limestone are waste residues, and therefore the coal consumption of clinker calcination is greatly reduced. The grinding yield of the raw material is greatly increased, energy sources are greatly saved, emission of CO2 is reduced, energy conservation and emission reduction are achieved, and the method accords with the national energy conservation and emission reduction environmental-protection concept; by the adoption of the scheme, the waste residues, such as the gangue, coal ash and mining barren rock are consumed greatly, and environmental pollution is reduced; besides, production cost can be reduced, and economic benefits can be increased.