The current Global Navigation Satellite Systems like the modernized Global Positioning System(GPS) and Galileo adopted a new modulation, Binary Offset Carrier (BOC), for new navigation signals. By using the new type of modulation, new navigation signals are better than traditional signal (GPS L 1 C/A) at code tracking and multipath mitigation. However, there are multiple side peaks along with the main peak in autocorrelation of this modulation. Therefore, this modulation causes challenges in code synchronization. This paper presents a new method of side-peaks cancellation to remove side peaks while keeping the narrow main peak. The proposed method could be applied to cosine-BOC(n,n) modulated signals, which are used to new navigation signals.