We demonstrated a robust spike cancellation by virtue of optical balancing technique for the near-infrared single-photon detection based on InGaAs/InP avalanche photodiode. A 31 dB suppression of the spike noise provided an efficient technique to read out weak avalanche currents at the early built-up, allowing the study on the photon number resolving dynamics of the InGaAs/InP avalanche photodiode. With the detection efficiency varied from 1% to 36%, the avalanche gain was shown to vary from the linear mode to the saturated mode and evidenced as a sub-saturated avalanche state. Multi-photon avalanche saturation was observed at different photon numbers as the avalanche gain varied. A photon-number-resolving detection was achieved with the detection efficiency as high as 36%.