A knocking detector for internal combustion engines includes an illumination detector for detecting the illumination intensity of combustion of the air-fuel mixture in the combustion chamber and a knocking discriminator for deciding whether or not a knocking has occurred on the basis of a signal produced from the illumination detector. The illumination detector is provided on the cylinder head of the internal combustion engine and is sensitive only to the light longer in wavelength than the near infrared rays.