Energy efficiency != green footprint. Gas is amazingly efficient, near 100%, certainly as good as a heat pump on 100% carbon neutral energy. However the green footprint it awful compared to an electric heatpump.
Amazingly a modern heat pump running on electricity generated by 100% gas is more efficient at heating than burning the gas for heat directly. Modern heat pumps are 5x efficient so you break even at even just 20% thermal efficiency of the power plant and gas plants are much more efficient than that. If you use the waste heat of the power plant for something else useful it's even better. Switching everyone to heat pumps would help even if 100% of your grid electricity was obtained by burning gas and obviously pretty much everywhere does much better than that.
> "Gas is amazingly efficient, near 100%, certainly as good as a heat pump on 100% carbon neutral energy."
Heat pumps achieve far in excess of 100% efficiency. You get several times more heat energy out than electrical energy goes in.
Of course, gas has in previous years been very cheap in many regions. So despite their efficiency advantage, often there hasn't been enough of an economic advantage to justify the upfront cost. But with the recent gas crisis, that might now be changing in Europe.