The thickness dependence of the spontaneous polarization and the hysteresis loop of epitaxial PbZr0.4Ti0.6O3 thin films deposited on (001) SrTiO3 substrate was investigated via the Landau-Devonshire's phenomenological theory considering the coupling of the stress field of the edge dislocation and the polarization. The results show that the critical thickness for the formation of misfit dislocation is ~1.27nm, and there is a drastic variation in the polarization near the dislocation in films with thickness greater than the critical value, which results in the formation of the dead layer that severely degrades ferroelectric properties. With decreasing the film thickness, both the dislocation spacing and the ratio of the dead layer to film total thickness increase. The thickness dependence of the hysteresis loop indicates that the remnant polarization decreases as the thickness decreases.