Hundreds of thousands of tonnes of wheat were stranded at a major port in India on Tuesday after New Delhi's surprise ban on exports over inflation and food security worries.

India, the world's second-largest grower of wheat, last week ordered that traders could not enter into new export deals without government approval.

The snap announcement has led to chaos at the port in Kandla, in Gujarat, where about 4,000 trucks are stuck in queues outside, according to the port operator.

Four ships partially loaded with about 80,000 tonnes of wheat are also docked at the facility.

Port officials said trucks that arrived before May 13, when the government announced the export ban, would be allowed to unload the grain onto ships waiting to take it to countries including Egypt and South Korea under prior agreements.

"However, those wheat-laden trucks that arrived at the port after May 13 will have to return with the commodity," said Om Prakash Dadlani, spokesman for operator Deendayal Port Trust.

The Gandhidham Chamber of Commerce estimated that about 400,000 tonnes of wheat from Punjab, Haryana, Madhya Pradesh and other wheat-growing states were stranded.

Between 500 and 700 warehouses near the port were "full of wheat for export", said Teja Kangad, president of the chamber.

A girl harvests wheat in a field on the outskirts of Faridabad in India
A girl harvests wheat in a field on the outskirts of Faridabad in India AFP / Money SHARMA

The government should have given prior notice before announcing the ban, he said.

"This has led to a chaotic situation where the truckers and traders are left uncertain of what will happen to the goods. Also, wheat being a perishable commodity, it can't be kept in the open for long," Kangad told AFP.

The wheat ban has drawn criticism from the Group of Seven nations worried about protectionism as inflation soars in the wake of the Ukraine war.

India had previously said it was ready to help fill some of the supply shortages caused by Russia's February invasion of Ukraine, which had accounted for 12 percent of global exports.

While India is a small exporter, its assurances of supplies from its large buffer stocks had provided some support to global prices and soothed fears of major shortages.

India's wheat production has been hit by searing temperatures -- the country recorded its warmest March on record -- prompting the government to predict output would fall at least five percent this year from 109 million tonnes in 2021.

Wheat prices surged to a record high on Monday, jumping to 435 euros ($453) per tonne as the European market opened.