China has ordered the closure of the US consulate in the south-western city of Chengdu, in a tit-for-tat escalation between the two countries.
China said the move was in response to the US closing its consulate in Houston, and accused staff in Chengdu of meddling in its internal affairs.
Secretary of State Mike Pompeo said the US decision was taken because China was "stealing" intellectual property.
Tensions have been rising between the US and China over several key issues.
President Donald Trump's administration has clashed repeatedly with Beijing over trade and the coronavirus pandemic, as well as China's imposition of a controversial new security law in Hong Kong.
On Friday, Washington urged China to "cease these malign actions rather than engage in tit-for-tat retaliation".
China's move came hours after Mr Pompeo hardened his tone further in a speech on Thursday at the library of former President Richard Nixon, whose 1972 China visit heralded a period of improved relations.
"Today, China is increasingly authoritarian at home, and more aggressive in its hostility to freedom everywhere else," Mr Pompeo said.
"The free world must triumph over this new tyranny."
What has China said?
On Friday, China's foreign ministry said it was closing the US consulate in Chengdu after staff there "interfered in China's internal affairs, and endangered China's security and interests".
During a news conference, ministry spokesman Wang Wenbin also said the US decision to close the consulate in Houston was based on "a hodgepodge of anti-Chinese lies".
He said Mr Pompeo's announcement on Thursday was "filled with ideological bias and a Cold War mentality."
"Pompeo made a speech in which he made a malicious attack on the Chinese Communist Party," Mr Wang said, adding: "To this, China expresses strong indignation and resolute opposition."
The ministry earlier said that the closure of the US consulate in Chengdu was a "legitimate and necessary response" to the actions taken by the US.
"The current situation between China and the United States is something China does not want to see, and the US bears all responsibility for that."
China has given the US until Monday to close the consulate in Chengdu, according to the editor of China's Global Times.
The mission, established in 1985 and currently having more than 200 staff - 150 hired locally - is seen as strategically important because it allows the US to gather information on the autonomous region of Tibet, where there has been long-running pressure for independence.
With its industry and growing services sector, Chengdu also is seen by the US as providing opportunities for exports of agricultural products, cars and machinery.
Why did the US order the Chinese consulate to close?
On Tuesday, the US government ordered China to close its consulate in Houston, Texas, by Friday.
The move came after unidentified individuals were filmed burning paper in bins in the building's courtyard.
Mr Pompeo accused China of stealing "not just American intellectual property... but European intellectual property too... costing hundreds of thousands of jobs".
"We are setting out clear expectations for how the Chinese Communist Party is going to behave. And when they don't, we're going to take actions," he said.
The Chinese consulate in Houston was one of five in the US, along with the embassy in Washington DC. It was not clear why it was singled out.
China's foreign ministry spokeswoman said the reasons given by the US for closing the consulate were "unbelievably ridiculous".
Hua Chunying urged the US to reverse its "erroneous decision", or China would "react with firm countermeasures".
In a further US move, four Chinese nationals have been charged with visa fraud for allegedly lying about their membership of China's armed forces. On Friday, US officials told reporters a Chinese student who fled to China's consulate in San Francisco was now in US custody. Three others were arrested earlier.
Separately, a Singaporean man has pleaded guilty at a federal court in Washington to a charge of operating as an illegal agent of the Chinese government, John Demers, assistant attorney general for national security, said on Friday.
Jun Wei Yeo, also known as Dickson Yeo, was charged with using his political consultancy in the US as a front to collect information for Chinese intelligence.
Why is there tension between China and the US?
There are a number of things at play. US officials have blamed China for the global spread of Covid-19. More specifically, President Trump has alleged, without evidence, that the virus originated from a Chinese laboratory in Wuhan.
And, in unsubstantiated remarks, a Chinese foreign ministry spokesman said in March that the US military might have brought the virus to Wuhan.
The US and China have also been locked in a tariff war since 2018.
Mr Trump has long accused China of unfair trading practices and intellectual property theft, but in Beijing there is a perception that the US is trying to curb its rise as a global economic power.
The US has also imposed sanctions on Chinese politicians who it says are responsible for human rights violations against Muslim minorities in Xinjiang. China is accused of mass detentions, religious persecution and forced sterilisation of Uighurs and others.
Beijing denies the allegations and has accused the US of "gross interference" in its domestic affairs.
What about Hong Kong?
China's imposition of a sweeping security law there is also a source of tension with the US and the UK, which ruled the territory until 1997.
In response, the US last week revoked Hong Kong's special trading status, which allowed it to avoid tariffs imposed on Chinese goods by the US.
The US and UK see the security law as a threat to the freedoms Hong Kong has enjoyed under a 1984 agreement between China and the UK - before sovereignty reverted to Beijing.
The UK has angered China by outlining a route to UK citizenship for nearly three million Hong Kong residents.
China responded by threatening to stop recognising a type of British passport - BNO - held by many of those living in Hong Kong.