The nonlinear analysis of lateral load pile in clay and sand was carried out by p-y curve method.It used different p-y curve model to sand and clay, took m value and uniform ultimate resistance as model parameters.The soil body's deformation was distinguished as elastic zone and plastic zone during the iterative process through. finite difference method and iterative method,and a new computing model was established. Then it used fortran language to study the behavior of laterally loaded piles,and compared computation result with examples so as to prove that the model is suitable for the calculation between clay pile and sand one.