BEIJING — President Xi Jinping can now rule China for as long as he’d like.

On Sunday, nearly 3,000 delegates at China’s ceremonial parliament cast ballots in Beijing’s Great Hall of the People to amend the nation’s constitution, allowing Xi to remain president well past 2023, when he was due to step down.

The amendment was widely expected – the parliament, called the National People’s Congress, hasn’t voted down a Communist Party decision in its 64-year history. Yet it is a striking break from precedent. China added term limits to the constitution in 1982, after decades of Mao Zedong’s disastrous political campaigns showed the dangers of one-man rule.

Two delegates voted against the change, and three abstained, giving Xi 99.8 percent approval.

Xi would have likely been unhappy with much less, said Willy Lam, an expert on Chinese politics at the Chinese University of Hong Kong who has written a book about the Xi era.

“This constitutional revision came from him – it is fully his initiative, and it has been controversial within the party and among the people,” he said. “So he needs that extremely high approval reading to show that this is not a selfish initiative – this is not him wanting to become an emperor for life, but this is the will of the people.”

Xi holds three posts: general secretary of the Communist Party, chairman of the Central Military Commission, and president of the nation. The last is the least consequential, and the only one that carried term limits. State media has cast the revision as a common-sense move to bring the presidency into line with the other two posts.

Yet Xi’s landslide vote belies a deep anxiety among Chinese intellectuals, students and former officials about the implications of his seemingly limitless power.

Li Rui, a 100-year-old former secretary to Mao, sees parallels between Xi and his former boss. “The Soviet Union collapsed, but China didn’t collapse, because China’s cultural traditions preserved the Communist Party,” Li told the Hong Kong-based newspaper Ming Pao. “A country like China produced people like Mao Zedong. Now it gives birth to a Xi Jinping.”

Chinese students abroad have reportedly strewn flyers on campuses showing a photo of Xi superimposed with the words: “not my president.” Censors have rushed to block open discussion of the revisions on social media sites; on Sina Weibo, China’s version of Twitter, forbidden terms include “re-election,” “proclaiming oneself an emperor,” and “I don’t agree.” They have also banned images of Winnie the Pooh, a cartoon character that many Chinese internet users believe shares some of Xi’s features.