The energy of a photon E = hf = hc/λ can be quoted in electronvolts
which is easier to compare with energy levels.
The minimum energy needed to remove an electron from a metal surface is normally a few electronvolts.
An electron accelerated from rest through a potential difference V gains kinetic energy eV
so ½mv2 = eV.
Differences between electron energy levels in atoms are of the order of electronvolts, matching photons of visible light.
Photon energies, work functions and photoelectron kinetic energies must all be in joules before the photoelectric equation is used.
Because one electronvolt is much smaller than one joule, an energy expressed in electronvolts has a large numerical value.