Taiwan's election body has formally confirmed that Chen Shui-bian won last week's presidential race, as protests against the result gathered pace.
Protesters stormed the election body's offices
Opposition activists stormed the election body's offices and broke windows, raising tensions ahead of a large march planned for Saturday.
China issued its strongest statement on the uncertainty triggered by the extremely close result.
It said it would not "sit and watch" if the situation spiralled out of control.
"The mainland side will not sit and watch and do nothing if the post-election situation in Taiwan goes out of control, leading to social turmoil, endangering the lives and property of our Taiwan flesh and blood brothers and harming stability across the Taiwan strait," Beijing's Taiwan Affairs Office said in a statement.
China views Taiwan as part of its territory. It does not recognise the legitimacy of the elections, and has regularly threatened to invade if the island declared independence.
Beijing's statement was immediately criticised by Taiwan's Mainland Affairs Council, which described it as "interfering".
"Communist China is crudely interfering in our internal
affairs. If communist China triggers conflict, it will be despised by the
people of Taiwan," the statement said.
President Chen was re-elected by a margin of only 0.2% of the vote, hours after an
apparent attempt to kill him, which the opposition says unfairly influenced the election.
Mr Chen's opponent, Lien Chan of the nationalist Kuomintang (KMT), has demanded a recount and for the vote to be nullified.
Taiwan's Election Commission officially confirmed Mr Chen as the winner on Friday.
While the commission was meeting, scores of demonstrators backing Lien Chan forced their way past riot police into the building where the decision was being made.
They were prevented from entering the meeting itself.
Since the election, thousands of people have staged a noisy but peaceful protest outside the presidential office in Taipei.
A BBC correspondent in Taipei, Caroline Gluck, said that tens of thousands more are expected to join them to take part in a demonstration on Saturday which has been called by the KMT-led opposition to protest against the outcome of the vote.
The government has issued a statement calling on participants in the march to "exercise peace and reason."
Police investigating the attempted assassination of President Chen released the first images of an unidentified man walking away from the scene where he was shot.
The grainy images form a closed-circuit TV Camera showed a balding, middle-aged man in a yellow jacket and blue trousers walking briskly away from the scene.
Police said there was no other evidence to link him to the attack, but they wanted to identify him.
"He is not a suspect yet, but there are some suspicions," said Wang Wen-chung, a deputy police chief in Tainan, where the shooting occurred.
President Chen has said the assassination attempt was genuine and rejected allegations of vote-rigging.