The hacking of Google that forced the search engine to withdraw from mainland China was orchestrated by a senior member of the communist politburo, according to classified information sent by US diplomats to Hillary Clinton's state department in Washington.

The leading politician became hostile to Google after he searched his own name and found articles criticising him personally, leaked cables from the US embassy in Beijing say.

That single act prompted a politically inspired assault on Google, forcing it to "walk away from a potential market of 400 million internet users" in January this year, amid a highly publicised row about internet censorship.

The explosive allegation that the attack on Google came from near the top of the Communist party has never been made public until now. The politician allegedly collaborated with a second member of the politburo in an attempt to force Google to drop a link from its Chinese-language search engine to its uncensored google.com version.

A cable from the Beijing embassy marked as secret records that attempts to break into the accounts of dissidents who used Google's Gmail system had been co-ordinated "with the oversight of" the two politburo members.

The cyber assault was described to the Americans by a high-level Chinese source as "100% political in nature" and having "nothing to do with removing Google... as a competitor to Chinese search engines".

Last December Google said that it was hit by a "highly sophisticated and targeted attack on our corporate infrastructure". Part of it was aimed at the Gmail accounts of "Chinese human rights activists" – although in a statement released in January, Google said that there was no evidence the hackers were successful. Shortly after the attack, Google chose to abandon mainland China. It relocated to Hong Kong, where it was able to run an uncensored version of its website in English and Chinese, ending an awkward attempt to reconcile partial adherence to Chinese requirements with western democratic values.

While Google and the US suspected leading Chinese politicians were behind the hacking, neither the company nor the US government said so at the time. Diplomats even discussed whether China's most powerful man, Hu Jintao, the president, or his prime minister, Wen Jiabao, were "aware of these actions". The secret note sent back to Washington concedes that "it is unclear" whether advance knowledge of the attack went right to the top.

Google, whose motto is Don't Be Evil, entered China in 2006. In an attempt to gain market share from local rival Baidu, it launched Google.cn, in which results relating to Tibet, Taiwan and the Tiananmen Square massacre were among those filtered out.

Google retained a link to the unfiltered Google.com on its Google.cn website, which prompted months of tension before the January incident. A cable from Beijing records that Google was already sounding the alarm to the most senior American diplomat in the country at the time.

Dan Piccuta, the US chargé d'affaires, was told how the prominent politician had "recently discovered that Google's worldwide site is uncensored" after he "allegedly entered his own name and found results critical of him". Shortly afterwards, according to the cable, the Chinese government ordered "the three dominant SOE [state influence enterprises] telecoms [companies] to stop doing business with the company".

However, that was not enough to persuade Google to back down. The US embassy was told that "removing the link to Google.com is against the company's principles". It refused to block access to Google.com.

China then upped its attacks on Google, according to another cable. A group of Chinese internet users reported that Google China was "not effectively filtering pornographic sites" and the Chinese government blocked access to Google for 24 hours.

The documents reveal a close relationship between Google and the US authorities in China. In January, a few days after Google made the hacking public – without specifying who it believed was responsible – Hillary Clinton, the US secretary of state, made a speech in Washington entitled "remarks on internet freedom".

Clinton weighed in heavily on the side of Google, warning that "countries that restrict free access to information or violate the basic rights of internet users risk walling themselves off from the progress of the next century".

She called on the Chinese government to "conduct a thorough review of the cyber intrusions" without revealing that it was her own officials who believed the attack was co-ordinated from inside the Chinese politburo.