They are quite fungible for heating.
I don't know how prices compare, but UK is on a big drive to replace gas boilers in private homes with heat pumps. The main obstacle is actually poor general building standards and insulation. I believe German standards are quite a bit higher. Basically, the peak temperature produced by air-source heat pumps is lower than that from a boiler, so without better insulation they don't work so well (or something like that).