Abstract Domain structure and domain moving under the external field are closely related to properties such as piezoelectric, ferroelectric properties of ferroelectric thin films. So the study of influence of domain switching on the properties of ferroelectric thin film has a great significance to understand mechanism of properties and to regulate the properties of ferroelectric thin films. Several recent works have drawn attention to so-called charged domain walls, and the results show that the charged domain walls have great influence on the piezoelectric properties. Therefore, it is very important to develop a model to analyze moving of charged domain walls under the external field and which effecting on the properties of ferroelectric thin films. In addition, the interface has a great influence on the properties of ferroelectric thin films. So it is necessary to develop a model to analyze the influence of interface on the domain and properties of ferroelectric thin films. In this paper we develop a phase field model for the ferroelectric thin films with charged domain walls, and investigate the effects of the applied electric field, the misfit strain and the charge density in the charged domain walls on the ferroelectric properties of the film films. Meanwhile, the influence of interface on the domain structures and properties of ferroelectric thin films has been study. The main contents and conclusions of this paper are summarized as follows: A phase field model of the ferroelectric thin films with charged domain walls is developed and the switching of charged domain walls in applied electric field has been investigated. The results suggest that the model of charged domain walls switching is related to the direction of the applied electric field. When there is the positive x-axis direction applied electric field, charged domain walls switch from head-to-head (HH) and tail-to-tail (TT) domain walls to head-to-tail domain walls firstly, then switch to head-to-h