Solar panels rely on sunlight to generate electricity. When it is cloudy, the panels will still produce electricity, but not as much as on a sunny day. The solar panel's power output depends on the sunlight it receives.