Beijing declared a Canadian diplomat as "persona non grata" Tuesday in retaliation for Ottawa's expulsion of a Chinese consular official, over allegations of foreign interference.

Foreign Affairs Minister Mélanie Joly said she would speak Tuesday afternoon with Shanghai consul Jennifer Lynn Lalonde, whom she described in French as "a very respected career diplomat."

Earlier Tuesday, Beijing declared it would expel Lalonde in retaliation for Canada sending a Chinese envoy packing.

The Canadian Security Intelligence Service has alleged Zhao Wei, a consular officer for China in Toronto, was involved in a plot to intimidate Conservative MP Michael Chong and his relatives in Hong Kong.

Joly announced Monday that Canada had declared Zhao as "persona non grata," ordering him to leave the country days after noting that such a move would likely lead to consequences.

"What we decided to do was based on us considering all factors," Joly said Tuesday in English.

"It needed to be thoughtful, it needed to take some time, and we needed to make sure that we did this in a very serious manner."

China's Foreign Ministry said in a statement posted to its English website early Tuesday that China was deploying a "reciprocal countermeasure to Canada's unscrupulous move,'' which it said it "strongly condemns and firmly opposes.''

The statement said Lalonde, a consul working out of the Consulate General of Canada in Shanghai, has been asked to leave before May 13, and that China reserves the right to further react.

Prime Minister Justin Trudeau said his government would stand firm.

"We will take whatever action is necessary to continue to protect our democracy and show that we're standing up for our values and our principles," Trudeau told reporters Tuesday morning as he headed into a meeting with his cabinet on Parliament Hill.

"We understand there is retaliation but we will not be intimidated," he added. "We will continue to do everything necessary to keep Canadians protected from interference."

Joly said the federal government will update its guidance to travellers if it perceives the risk to Canadians in China as rising higher than its current level.

The current travel advisory asks Canadians to "exercise a high degree of caution in China due to the risk of arbitrary enforcement of local laws."

Calls for Zhao to be expelled began last week after a report in the Globe and Mail that CSIS had information in 2021 alleging the Chinese government was looking at ways to intimidate Chong and his relatives in Hong Kong. The federal government has confirmed that report.

Following Joly's announcement on Monday, China's embassy in Ottawa issued a statement that accused Canada of breaching international law and acting based on anti-Chinese sentiment.

It said the move "sabotaged'' relations between China and Canada, according to an official English translation provided by the embassy, and promised unspecified retaliatory measures.

Trudeau said Tuesday that his government had taken the potential for retaliation, including economic countermeasures, by China into account when it decided to expel the envoy.

"We will always do whatever is necessary to keep Canadians safe," Trudeau said.

This report by The Canadian Press was first published May 9, 2023.