Recently, I added solar power to one of my ESP8266 weather stations.
With the right hardware, this was actually remarkably easy to do. To make things nice and easy, I ordered an Adafruit USB/DC/Solar Li-Ion/Li-Poly charger. (Top-right in the photo) These boards can take DC input from USB, a 2.1mm power jack or from wires soldered directly onto the board. It will then both charge a Li-poly battery and power a load. Whatever power is left over from powering the load will be used to charge the battery, and if the load draws more than what the solar panel can provide, the rest will be drawn from the battery.