In the 19th century, it was observed that the sunlight striking certain materials generates detectable electric current - the photoelectric effect. This discovery laid the foundation for solar cells. Solar cells have gone on to be used in many applications. They have historically been used in situations where electrical power from the grid was unavailable.