Yes. Solar panels produce far more electricity when they’re in direct sunlight, but even when obstructed by rain, snow or dirt, they’re still capable of producing electricity.