Foreign Minister Wang Yi said if war occurred there could be no winner.
Mr Wang's comments come as the US voices increasing concern at North Korea's development of nuclear weapons and deploys a Navy carrier group off the Korean peninsula.
China, North Korea's only backer, fears conflict could cause the regime to collapse and problems on its border.
Mr Wang said: "One has the feeling that a conflict could break out at any moment.
“I think that all relevant parties should be highly vigilant with regards to this situation."