Dyes are generally small molecules that have electronic transitions with energies corresponding to the visible spectrum of light (around 1-3 eV).  Around 35 years ago, the idea was put forward, particularly by Michael Grätzel and Brian O'Regan , to couple dye molecules to semiconductors and electrolytes, so that when the dye molecules are excited by light, the electrons/holes can be captured and used for photovoltaic power.  This is the concept behind dye-sensitized solar cells , as demonstrated