The synchronization of complex networks is one of the key points to study the dynamic law of network. Due to the influence of external environment or physical conditions, nonlinear interference is inevitable. As a result, system parameters will not be obtained completely, which is not conducive to realize synchronization of network. In order to get system state variables and realize synchronization of complex networks with external interference. A synchronization control method is proposed based on the extended observer theory and sliding mode control theory in this paper. Firstly, aiming at the problem that the system state variables can't be obtained accurately. A method of designing extended observer is proposed to observe the unknown state variables of system. Secondly, on the basis of getting the system state variables, in order to realize system synchronization control, the synchronization controller is designed based on the sliding mode control theory. And the correctness of this method is proved by Lyapunov stability theory. Finally, the validity of the proposed method is verified by simulation of Lorenz chaotic system of random 30-node and IEEE39-bus system.