Image copyright AP Image caption Chinese Foreign Minister Yang Jiechi called the Japanese move illegal and invalid

A war of words over islands claimed by both Japan and China continued at the United Nations, as the US called for cooler heads to prevail.

In a speech, China's foreign minister accused Japan of stealing the islands, which lie in the East China Sea.

In reply Japan's deputy ambassador said the islands were Japanese territory and China's claim a recent development.

The US secretary of state had earlier urged both to "engage in dialogue to calm the waters", a diplomat said.

The islands, called Senkaku in Japan and Diaoyu in China, are also claimed by Taiwan. South of Okinawa and north of Taiwan, they are controlled by Japan.

Earlier this month, the Japanese government bought the islands from their private Japanese owner, reigniting a territorial row that has rumbled for years.

The row has seen a ceremony meant to mark Sino-Japanese ties cancelled and a number of Japanese businesses briefly halt production in some Chinese cities because of protests.

Both Chinese and Taiwanese fishing boats and surveillance ships have also been sailing in and out of what Japan says are its territorial waters - leading to warnings from Tokyo.

'Basic position'

Chinese Foreign Minister Yang Jiechi's comments came as he gave China's address to the UN General Assembly.

"The moves taken by Japan are totally illegal and invalid," he said. "They can in no way change the historical fact that Japan stole Diaoyu and its affiliated islands from China and the fact that China has territorial sovereignty over them," he said.

Japan-China disputed islands The archipelago consists of five islands and three reefs

Japan, China and Taiwan claim them; they are controlled by Japan and form part of Okinawa prefecture

The Japanese government signed a deal in September 2012 to purchase three islands from Japanese businessman Kunioki Kurihara, who used to rent them out to the Japanese state

The islands were the focus of a major diplomatic row between Japan and China in 2010 Q&A: China-Japan islands row

He also said that the Japanese government had "grossly violated China's sovereignty".

Japan's Deputy Ambassador Kazuo Kodama exercised a right of reply after Mr Yang's comments.

"There is no doubt that the Senkaku islands are clearly an inherent territory of Japan based on historical facts and international law," he said, adding China and Taiwan had only started laying claim to the area in the 1970s.

China's UN ambassador, Li Baodong, then chose to reply, hitting out at Japan's "obsolete colonial mindset".

Japanese Prime Minister Yoshihiko Noda told reporters at the UN on Wednesday that there was no territorial issue to discuss. "Therefore there cannot be any compromise that could mean any setback from this basic position."

In a meeting with Mr Yang on Thursday, diplomats said Hillary Clinton called for dialogue and efforts to reduce the tensions. Foreign ministers of Japan and China held talks earlier this week that were described as "severe".

The Japanese government moved to buy the islands in response to a potentially much more provocative plan by right-wing Tokyo Governor Shintaro Ishihara to buy and develop them using public donations.

The row comes at a time when both China and Japan are facing political changes domestically, making it difficult for either side to be seen as backing down.

Japan is also embroiled in another territorial row with South Korea - which is also heading into a presidential election - over a different set of islands, called Takeshima in Japan and Dokdo in South Korea.

On Friday Mrs Clinton will hold three-way talks with both the Japanese and South Korean foreign ministers likely to focus on repairing strained ties.