Electricity won't run out because electricity is generated with electrical generators.
However the fuels that are use to generate most of the electricity will eventually run out.
Electric power plants operate on natural gas, fuel oil and coal although some electricity is generated using water through hydroelectric power plants.
For the power plants that operate using natural gas, fuel oil and coal those power plants will eventually run out of fuel to operate.
However for power plants that use hydroelectric as the source or water then as long as the water is flowing the electricity will still be generated.
Also we now have wind generators as well as Solar power so as long as we have the sun and wind we'll still have electricity.