When electricity is passed through an aqueous solution of sodium chloride, it decomposes to form sodium hydroxide. The process is called chloralkali process because of the products formed chlor for chlorine and alkali for sodium hydroxide.
2 NaCl(aq) + 2H2 O(l) → 2NaOH(aq) + Cl2 (g) + H2 (g)
Chlorine gas is given off at the anode and hydrogen gas at the cathode and sodium hydroxide is formed near the cathode.