At present, most atomic spin precession detection schemes use discrete optical elements, which leads to bulky detection systems. However, chip-based spin precession detection schemes lack modulation, resulting in lower detection sensitivity. In this paper, we propose and simulatively demonstrate an integrated atomic spin precession detection scheme using an onchip Mach-Zehnder-like interferometer. An on-chip polarization sorter is designed, with contrast ratio of 24dB and coupling efficiency of 16.8% at 795 nm. With this device, linearly polarized probe light that experienced optical rotation can be split and coupled into two waveguide arms of the interferometer. To avoid the effect of low frequency noise, our scheme uses a micro-heater to modulate the phase difference signal, allowing for high sensitivity detection. The whole detection system can reach micron size, which provides a practical new technique for high precision atomic sensors that can be integrated into chips.