Yes, you can.
A hydro-powered heat pump is probably the most viable renewable power-source since it is fairly constant. Solar or wind inputs would be difficult, especially on a small scale. The outputs are variable and dependent on the weather so there can be problems matching the input power requirements. The very large number of photo-electric cells required to power a heat pump would probably make this option impractical.
Powering a heat pump from grid electricity derived from a renewable source (e.g. wind-farm or hydro) is a good option for the environment.