Simply put, a solar cell converts solar energy (energy generated from the sun) to electrical energy. Another term for this is photovoltaic cell.
So how does it work?
Atoms are composed of electrons, protons, and neutrons. Electricity is the flow of electrons, so as with other energy devices, we are interested in generating a flow of electrons. So how does all this work? Well first, a little science history lesson! In 1905, Albert Einstein won the Nobel Prize in physics in 1905 for explaining the nature of light and a phenomenon called the photoelectric effect. This laid down the theoretical groundwork for technology used in solar cells today.
A solar cell is composed of a semiconductor, an anti-reflective coating layer and electrodes. The main work-horse in a solar cell is the semi-conductor. A semi-conductor is a material whose electrical conductivity lies between that of an insulator (zero electrical conductivity), and a conductor (high electrical conductivity).
Succinctly, certain semiconductors exhibit the photoelectric effect, meaning, they absorb light and release electrons.
The semiconductor used in a solar cell is especially treated to be positively charged on one side (P-type) and negatively charged (N-type) on the other side. The point where this layers meet is called the P-N junction.
When light shines on the device, the anti-reflective coating layer traps the absorbed sunlight to maximize device performance. The semiconductor absorbs the trapped light and releases electrons. Electrons collect in the negatively charged layer of the semiconductor region and ‘holes’ (a name for the absence of electrons), collect in the positively charged layer. Therefore, when an electric load is connected to either end of the device, electrons flow from the positive electrode to the negative electrode completing the circuit!