In one widely circulated essay published by state news outlets titled “Nine Knockout Blows in America’s Cold War Against China,” the blogger, Zhou Xiaoping, argued that American culture was “eroding the moral foundation and self-confidence of the Chinese people.” He compared unfavourable American news coverage of China to Hitler’s treatment of the Jews. In another essay, he said the West had “slaughtered and robbed” China and other civilisations since the 17th century, and was now “brainwashing” it.

Mr. Xi, at a forum last month aimed at tightening political control of the arts, said the blogger exhibited “positive energy.”

His embrace of Mr. Zhou, who has been hailed by propaganda officials but widely mocked by scholars here, is just the latest sign of rising anti-Western sentiment, bordering on xenophobia, that has emanated from the highest levels of the Communist Party and sent a chill through Chinese civil society and academia.

Using ideological language reminiscent of the Cold War, Chinese officials have voiced conspiracy theories with relish, accusing foreigners, their companies, government agencies and non-governmental organisations of plotting to weaken or overthrow the party. Chinese institutions with ties to Western entities, no matter how benign, have also come under attack. Meanwhile, state-run newspapers have taken to blaming “hostile foreign forces” for any major disturbance, whether it is ethnic violence in western China or student-led pro-democracy demonstrations in Hong Kong.

The vilification of foreigners as enemies of China has been a staple of propaganda by the Communist Party since before its rise to power, and analysts say the leadership tends to ramp up such rhetoric when it feels under pressure at home.

“Historically, during every period with many deep conflicts within the country, there has been a surge of anti-foreign sentiments from the party,” said Zhang Lifan, a historian, pointing to Mao Zedong’s disastrous Cultural Revolution as an example. At the moment, he said, “the political establishment needs the public to turn their rage toward foreign countries” because anger over the widening gap between rich and poor in China has reached “crisis levels.”

But unlike earlier campaigns targeting the West, the current wave of nationalism comes as China is ascendant. Mr. Xi presides over a country that is on the verge of overtaking the United States as the world’s largest economy and that enjoys influence around the world, especially in Asia, where it has sought to expand its territorial footprint.

In speeches, Mr. Xi has openly called on other nations to push back against the United States on specific issues. In July, for example, he told Brazil’s National Congress that developing nations must “challenge U.S. hegemony on the Internet.” Two months earlier, Mr. Xi suggested at a conference in Shanghai that the United States should cede power in Asia, saying, “It is for the people of Asia to run the affairs of Asia.”

The surge in anti-Americanism extends beyond speeches. Over the summer, for example, the Chinese government began a security review of foreign non-governmental agencies operating in China, as well as Chinese non-governmental agencies that receive foreign support, scrutinising their finances and freezing bank accounts. A 100-minute anti-American propaganda film made by the People’s Liberation Army last year laid out the case that American non-governmental agencies were out to undermine the party. (It used the martial theme music from the HBO series “Game of Thrones.”)

In Guangdong, the province adjacent to Hong Kong that has long been more open to foreign influence and investment, officials have considered shutting down Chinese non-governmental agencies that depend on foreign funds, the state-run newspaper Global Times reported last week.

Wang Jiangsong, a professor of labour relations at the China Institute of Industrial Relations, was quoted in the newspaper as saying that the authorities had secretly tracked transfers of overseas money to the Chinese organisations, and were worried that “some NGOs would be manipulated by overseas forces and conduct activities that may endanger national security and undermine social stability.”

The campaign has reached into academia as well. An employee of an American organisation that promotes dialogue among scholars said some Chinese professors who work on international relations were no longer writing or saying anything in public that casts the United States in a positive light, for fear of being accused of spying. The employee, who spoke on the condition of anonymity so as not to antagonise Chinese partners, added that one Chinese university had barred visiting American scholars from lecturing if their research did not conform to the party line.

Casting blame on the “black hand” of foreign forces has become more common in the state news media as well. The People’s Daily has published 42 articles this year blaming “Western,” “foreign” or “overseas” forces for China’s domestic problems. That total is nearly triple the number of similar pieces from the first 10 months of last year, according to a count by The Christian Science Monitor.

The pro-democracy demonstrations in Hong Kong have been a favourite target. Last Friday, Ta Kung Pao, a Hong Kong newspaper close to the party, ran a front-page article under a headline that said the newspaper had found “ironclad evidence” that the United States had been secretly plotting the local Occupy movement since 2006.

The government has also targeted major Western companies with high-profile investigations and imposed record fines for what officials call monopolistic practices. Some foreign businesspeople and officials say the investigations are a form of protectionism. At the same time, the Chinese government has maintained restrictions on foreign investment, ownership and market access in many industries.

As a result, American executives have tempered their optimism about doing business here, said John Frisbie, president of the U.S.-China Business Council, a trade group in Washington. “It should be more than a $350 billion market in China for U.S. companies,” he said. “Many sectors are still closed. There has generally been a lack of movement forward on further openings.”

Some have questioned the sincerity — or pointed out the hypocrisy — of the party’s tirades against the West, noting that many party officials have children or other family members living and even applying for citizenship overseas. Mr. Xi’s daughter, Xi Mingze, attended Harvard University under a pseudonym.

“How can Chinese officials really be anti-American?” asked Zhan Jiang, a media studies professor at Beijing Foreign Studies University. “Anti-foreign sentiments will always be present in China because of China’s unique history,” he said. “However, the public’s opinion of the West will not change because of what the party says.”