In this work, undoped and Mg doped (at the Mg percentages of 1, 3 and 5) copper oxide films were deposited at the substrate temperature of 300 +/- 5 degrees C by ultrasonic spray pyrolysis technique, and the effect of Mg incorporation on the optical, structural and electrical properties was presented. Optical properties of the films were analyzed by transmission, linear absorption coefficient and reflection spectra, and the optical method was used to determine the band gaps of the films. The film structures were studied by X-ray diffraction, and the texture coefficient (P), the grain size (D), and macrostrain (< e >) for preferential orientations were calculated. The electrical conductivities were calculated with two-probe technique. Consequently, it was determined that Mg incorporation has a strong effect on the optical and especially structural properties of the copper oxide films.