Energy stored in a capacitor

Charging a capacitor stores energy $U_C = \frac{1}{2}Q\Delta V = \frac{1}{2}C(\Delta V)^2$, half of what the battery supplies, because each new bit of charge is pushed against the voltage already built up.

From AP Physics 2.