Electrons are ejected from a substance as a result of the photoelectric effect, which is caused by electromagnetic radiation. Einstein hypothesized that photons are electromagnetic radiation quanta with energy E=hv, where h is the radiation frequency. Photons make up all electromagnetic radiation.