A device that converts energy of combustion of fuels like hydrogen and methane, directly into electrical energy is known as
fuel cell
electrolytic cell
dynamo
Ni-Cd cell
In thermal power plants. electricity is produced by using chemical energy of fossil fuels like coal etc.