A solar panel converts sunlight into electricity. It is made up of cells that have a special property called the photovoltaic effect. When sunlight hits these cells, it creates an electric current by energizing electrons in the material. The flow of energized electrons generates direct current (DC) electricity. Multiple solar cells are connected together to form a solar panel, and multiple panels are wired together to create an array. The DC electricity is then converted to alternating current (AC) using an inverter, making it compatible with the electrical system of a building. The generated electricity can be used to power appliances and devices, stored in batteries, or sent back to the grid.