Earlier quoted context omitted.
There's been talk of replacing the natural gas used directly for heating in the UK with hydrogen. I have absolutely no idea how viable that will actually prove to be but it seems difficult.
So technically it might be possible to do that. But I don't think the economics would work out for that. Mostly because your cost of hydrogen will then be linked to the cost of electricity coming in. Given the choice between hydrogen which will cost the base electricity prices + overhead of electrolysis plants and transportation or to just use a resistive heater, you would most likely pick the resistive heater since…
IF the capital cost of electrolysis isn't too bad - and this paper suggests that it can be done more cheaply than the current use of platinum - then it's economical to run them with zero or negative cost electricity produced by renewables overbuild, then keep the hydrogen in tanks (another if) or convert it to actual natural gas via the sabatier reaction and keep that. That may be cheaper than building really huge battery farms for long-duration electric storage.