In order to solve the problem of pile-soil interaction under dynamic loads, a frequency domain substructure analysis method was proposed based on the assumption that the pile and structure were equivalent to one-dimensional rods and the soil was assumed to be a viscoelastic medium. Firstly, based on the continuum mechanics method, the soil governing equation was decoupled by introducing the potential function. The expressions of displacement and stress of the soil around the pile were derived from the boundary conditions, and the expressions of horizontal resistance in the homogeneous soil were derived from the pile-soil coupling continuity conditions. Then, the pile and structure were discretized using beam elements and a dynamic-stiffness matrix between the soil resistance and the structural displacement was obtained through finite element discretization. The dynamic-stiffness matrix was further combined with the finite element model of the pile and the structure to form the coupled finite element equation. Thus, the frequency domain substructure model for the dynamic response of the structure-pile-soil system was established. Finally, the method was verified by the threedimensional finite element model in ABAQUS software. The proposed model was used to analyze the effects of soil dynamic stiffness, soil damping and soil model on the dynamic response of the structure, and the effects of uniform and non-uniform ground motion excitation on the seismic response of the structure.