That said, in my home, I use net metered photovoltaic panels with a Rheem heat pump for domestic hot water. This was not done because I considered it to be a better solution, but because it was the only solution available to me from local installers.
Solar thermal heating used to make more sense but cost of photovoltaics has come down so much along with relatively cheap heat pump systems nobody is doing the former anymore it seems.
I just got a large solar system installed and next up is a heat pump water heater as thats the second largest user of power next to the HVAC, plus it will cool and dehumidify my garage some where the solar inverter and batteries are located, converting some of the waste heat from the inverter into hot water at the same time.
https://www.energy.gov/energysaver/heat-pump-water-heaters