Electrolysis: Electrolysis is the process of decomposition of a chemical compound in an aqueous or molten state accompanied by a chemical change using a direct electric current.
Example:When current is passed through molten sodium chloride, sodium ions and chloride ions are deposited at different electrodes. So, sodium chloride decomposes into sodium and chloride ions by passing a direct electric current.