regenerative fuel cell

Regenerative fuel cells produce electricity from hydrogen and oxygen and generate heat and water as by-products, just as other fuel
cells do. However, regenerative fuel cell systems can also use electricity
from solar power or some other source to divide the excess water into oxygen
and hydrogen fuel, a process known as electrolysis.
This is a comparatively young fuel cell technology being developed by NASA
and others.