A precursor solution was prepared by dissolving nickel chloride salt and citric acid in butanol and ethanol. The solution was refluxed under continuous stirring and adding predetermined amount of water (solution in solvent). The thin films were deposited by dip-coating methods. The thin films were analyzed by TG, DSC, TEM, SEM, XRD and cyclic voltammetry. The influence of heat treatment temperature on film transmittance in the range of 350 nm to 850 nm was discussed. Results show that the thin film can transform from amorphous into cubic-NiO nanocrystalline by means of heat treatment. The results of cyclic voltammetry of the films, carried out in an electrochemical cell with three electrodes and 0.1 mol/L KOH electrolyte show that the NiO thin film treated at 350degreesC for 30min has a good electrochromic performance. As given voltage, the films reversibly change their colors from transparent to brown, and their transmittance can modulate from 80% to 30%. The cyclic voltammeter results also show that the film is quick to reach its electrochromic stable condition.