The chief cabinet secretary, Osamu Fujimura, told reporters Japan would buy the three uninhabited islands in the East China Sea from a private Japanese family it recognises as the owner, and has budgeted 2.05bn yen (£16m) for the purchase.
China and Taiwan also claim the islands, which are part of what Japan calls the Senkakus and China the Diaoyu group.
Fujimura said the decision to nationalise the islands was "to maintain the Senkakus peacefully and stably".
The deal was signed with the family on Tuesday morning, public broadcaster NHK said.
The dispute, which has long been a flashpoint in Japan-China relations, has been heating up in recent months.
Fujimura repeated that the islands were part of Japan's territory, and should cause no friction with other countries or regions. "We certainly do not wish the issue to affect our diplomatic relations with China and it is important to avoid any misunderstanding or an unexpected event," he said.
Tuesday's formal cabinet approval came the day after Fujimura announced the decision, prompting a swift response from China's foreign ministry, which said Beijing would not "sit back and watch its territorial sovereignty violated".
"China strongly urges Japan to immediately stop all action to undermine China's territorial sovereignty and return to a negotiated settlement to the dispute. If Japan insists on going its own way, it will bear all the serious consequences that follow," the ministry said in a statement.
State-run China Central Television reported that the foreign minister, Yang Jiechi, summoned the Japanese ambassador to complain about the purchase.
All major state newspapers in China ran the ministry statement on their front pages on Tuesday, along with comments from Chinese premier, Wen Jiabao.
"The Diaoyu Islands are an inalienable part of China's territory, and the Chinese government and its people will absolutely make no concession on issues concerning its sovereignty and territorial integrity," Wen said at the inauguration ceremony for a statue of the late Chinese leaders Zhou Enlai and Chen Yi at the China Foreign Affairs University in Beijing.
Japanese supporters think having the government own the islands will strengthen Japan's claim over them, and send a tougher message to China.
Experts in Japan said the government's move was also meant to block a plan by Tokyo's nationalistic governor to buy the islands and develop them – a move that would have inflamed ties with China even more. The islands would not be developed under the deal approved on Tuesday.
Earlier this month, the city of Tokyo sent a team of experts to waters around the islands to survey fishing grounds and possible sites for development, in a move that was strongly criticised by China. Activists from Japan and Hong Kong briefly set foot on the islands last month, and there have been protests in various Chinese cities in recent weeks.
The dispute over the islands boiled over into a major diplomatic row between the two neighbours after an incident on 7 September 2010 in which a Chinese fishing boat collided with Japanese coastguard ships near the islands. The fishing boat captain was arrested and later released.