The correct answer is a. Chemical reaction. Batteries produce electricity through an electrochemical reaction that converts chemical energy into electrical energy. The chemical reaction takes place between the electrodes and the electrolyte of the battery, producing a flow of electrons that can be harnessed as electrical energy.