Or I have used the oil boiler in the basement, if Norway didn't ban that in 2020. That would have freed up enough electricity for several homes in the UK or Germany.
Electrical heating is fine if all electricity produced is from hydro, nuclear or wind/solar, but it makes less sense if the grid relies too much on fossil fuels.
But you do have to transport the gas or electricity to the heating site, and I don't know how that adds up.
Also, if conditions are right, you can use electricity to run a heat pump and move heat from the outside air to the inside air; depending on the details, you can move a lot more watts of heat then you spend operating the heat pump. This can be more economical than direct heating.
Heat pumps are great and super cool but if you include the efficiency of generation it's unlikely to be more energetically efficient, yes.
It's close though, natural gas combined cycle plants are very efficient for what they are. And if the heater is electric, substitution for other electricity sources is possible... unlike now.