Einstein explained the effect by postulating that a beam of light is a stream of particles (photons), and that if the beam is of frequency f then each photon has an energy equal to hf. An electron is likely to be struck only by a single photon, which imparts at most an energy hf to the electron. Therefore, the intensity of the beam has no effect; only its frequency determines the maximum energy that can be imparted to the electron.
To explain the threshold effect, Einstein argued that it takes a certain amount of energy, called the work function, denoted by φ, to remove an electron from the metal. This amount of energy is different for each metal. If the energy of the photon is less than the work function then it does not carry sufficient energy to remove the electron from the metal. The threshold frequency, f0, is the frequency of a photon whose energy is equal to the work function:
If f is greater than f0, the energy hf is enough to remove an electron. The ejected electron has a kinetic energy EK which is, at most, equal to the photon's energy minus the energy needed to dislodge the electron from the metal:
Einstein's description of light as being composed of particles extended Planck's notion of quantised energy: a single photon of a given frequency f delivers an invariant amount of energy hf. In other words, individual photons can deliver more or less energy, but only depending on their frequencies. However, although the photon is a particle it was still being described as having the wave-like property of frequency. Once again, the particle account of light was being "compromised".
The relationship between the frequency of electromagnetic radiation and the energy of each individual photon is why ultraviolet light can cause sunburn, but visible or infrared light cannot. A photon of ultraviolet light will deliver a high amount of energy—enough to contribute to cellular damage such as occurs in a sunburn. A photon of infrared light will deliver a lower amount of energy—only enough to warm one's skin. So an infrared lamp can warm a large surface, perhaps large enough to keep people comfortable in a cold room, but it cannot give anyone a sunburn.