How to quickly and accurately detect the error of NC machine has become a hot issue for domestic and foreign scholars. Based on GPS principle, a laser tracker is adopted the multi-station and time-sharing measurement to rapidly and accurately detect the geometric accuracy of NC machine. The machine is controlled to move in the preset path, and a laser tracker is used to measure the same motion trajectory of the machine successively at different base stations. The position of base station and the space coordinates of measuring points can be determined based on large amount of measured data. The algorithms of multi-station and time-sharing measurement are given, and the influencing factors of measurement results are discussed in the paper. Meanwhile, a detection system of machine error is developed based on the platform of Matlab, which can quickly process the measured data and shows each error of machine intuitively.