In 725, when Emperor Xuanzong was set to offer sacrifices to heaven and earth at Mount Tai, the chancellor Zhang Shuo, a major proponent of the sacrifices, was apprehensive that certain hostile foreign powers may take the opportunity to attack, and considered fortifying the borders. He discussed the matter with Pei. Pei pointed out that the sacrifices at Mount Tai were intended to show the power of the state, and fortifying the borders would in fact show apprehension, not power. Instead, he pointed out that among the foreign powers, Eastern Tujue was the strongest, and that if the Eastern Tujue khan Ashina Mojilian would be willing to show submission by sending a key official to attend to Emperor Xuanzong, then the other foreign states would do so as well. Zhang was impressed with his proposal and submitted it to Emperor Xuanzong, and Emperor Xuanzong agreed. Subsequently, Pei was made the deputy minister of vassal affairs (鴻臚少卿, Honglu Shaoqing). After Emperor Xuanzong returned from Mount Tai, Pei was made the deputy minister of defense (兵部侍郎, Bingbu Shilang).