In this paper, a second-order operator splitting method combined with the barycentric Lagrange interpolation collocation method is proposed for the nonlinear Schrödinger equation. The equation is split into linear and nonlinear parts: the linear part is solved by the barycentric Lagrange interpolation collocation method in space combined with the Crank–Nicolson scheme in time; the nonlinear part is solved analytically due to the availability of a closed-form solution, which avoids solving the nonlinear algebraic equation. Moreover, the consistency of the fully discretized scheme for the linear subproblem and error estimates of the operator splitting scheme are provided. The proposed numerical scheme is of spectral accuracy in space and of second-order accuracy in time, which greatly improves the computational efficiency. Numerical experiments are presented to confirm the accuracy, mass and energy conservation of the proposed method.