In the present study, a new method for analyzing the dielectric functions in dependence with the thickness of ultra-thin gold films is proposed. The reliability of the method is carefully verified through the correlation of optical properties and structural morphology of gold films at thicknesses around the percolation threshold (from 2 to 20 nm). The optical characterization of deposited films is performed in visible and NIR regions (300-1500 nm) by a spectroscopic ellipsometry along with transmission spectra measurements at normal incidence. Fitting of the ellipsometric data allows one to calculate the effective complex dielectric function of cluster-like and continuous films of different mass-equivalent thickness. Surface morphology of the films is analysed by scanning electron microscopy.