Viktor Orban said migrants entering Hungary in their thousands in the past weeks had “rebelled” against his police force, and order had to be restored.
Aid workers have been telling of “abysmal” conditions for refugees at a camp on the Hungarian-Serbian border.
Video footage has emerged of people being thrown bags of food at the camp in the town of Roszke.
Hungary has struggled to cope with some 150,000 migrants that have crossed its borders so far this year, en route from Greece to countries in northern and western Europe.
There have been tensions between the authorities and migrants, at border areas and key railway stations.
Mr Orban has now warned that tougher immigration laws will take effect from 15 September and anyone crossing the border illegally could expect to be arrested.
He praised the police for doing a “remarkable” job “without force” in the face of unco-operative migrants who, he said, had “rebelled against Hungarian legal order”.