A classical SU(2) Einstein-Yang-Mills theory in 3+1 dimensional anti-de Sitter spacetime is believed to be dual to a p-wave superconductor in 2+1 dimensional flat spacetime. In order to calculate the superconductiong coherence length $\xi$ of the holographic superconductor near the superconducting phase transition point, we study the perturbation of the gravity theory analytically. The superconductiong coherence length $\xi$ is found to be proportional to $(1-T/T_c)^{-1/2}$ near the critical temperature $T_c$. We also obtain the magnetic penetration depth $\lambda\propto(T_c-T)^{1/2}$ by adding a small external homogeneous magnetic field. The results agree with the Ginzburg-Landau theory.