How do batteries give the electrons their energy?

When a coulomb (of electron) flows through a resistor, it loses the energy it gained in the battery. How were these electrons fueled in the battery in the first place? I already know that chemical reactions rearrange electrons in the battery. But this doesn't directly address the energy gain (voltage) in the battery.

In a battery, chemical reactions provide for an electrical "potential difference" of the electrodes.
If you are confused, remember that these types of reactions are not perpetually sustainable in a 'closed' system.
They work for a while, then not.

Staff: Mentor

Hi sodium.dioxid, welcome to PF

Remember that energy is the capacity to do work and that work is f.d, so fundamentally a battery works by giving a small f over a microscopic d that literally pushes on the electron. That is where the energy comes from, that microscopic push.