A method for preventing the knocking of spark-ignition engines. The technical problem of the invention lies in detecting the knocking state by analysing the cylinder pressure curve in its apex area. In the area of the top dead centre at least one measuring spark is ignited inside the combustion chamber. The peak voltage and/or duration of combustion of each measuring spark is measured. If the measurements are less than adjustable threshold values for the peak voltage and/or duration of combustion, a correction signal which causes a shifting of the ignition spark initiation towards the top dead centre is generated.