BEIJING — Chinese President Xi Jinping is urging the semiautonomous former Portuguese colony of Macau to guard against interference by what he called hostile external forces after prolonged pro-democracy protests in nearby Hong Kong.

Xi's Saturday remarks come after Beijing accused foreign forces of fostering the pro-democracy Occupy Central movement in Hong Kong, where protesters demanded a right to nominate candidates for the territory's next chief executive. The 79-day demonstration ended in mid-December. The U.S. has denied it fostered the protests.

Xi is visiting Macau to mark the 15th anniversary of its return to Beijing.

Both Hong Kong and Macau are special administrative regions where Beijing allows greater autonomy under the "one country, two systems" arrangement. However, Beijing does not want to the regions to become hotbeds of democracy movements.