The invention provides a new method to recycle compound semiconductor materials used in the photovoltaic industry by employing ambipolar electrolysis (AE). The proposed process selectively dissolves the semiconductor material off the solar cell into a molten salt bath, leaving behind the glass and metal wire contacts. AE can then be performed on the molten salt containing the dissolved compound, resulting in the simultaneous electrodeposition of the two metals onto separate electrodes. To recycle CdTe, the molten salt can be CdI2 or CdCl2-KCl, and the operating temperature is 500°C. Given the high purity of the collected molten metals, Cd and Te products could be remixed under N2, producing CdTe, ready to be reintroduced into the manufacturing stream of new solar cells.