By electrolysis of the methanol and urea solutions CNx thin films have been synthesized on silicon substrates at atmospheric pressure and low tempreture (60℃). The FTIR and Raman measurements show that the films are amorphous carbon network with the staples of many C—N, C—C, C=C and C=N bonds and a small portion of C≡N bonds. The XPS measurements indicate that nitrogen atoms is chemically bonded to carbon atoms through hybridized SP2 and SP3 configurations. The structures of the amorphous CNx thin films deposited by this method are every similar to those by vapor depositions.