If national security is endangered, Serbia will close its borders hermetically, said President Aleksandar Vucic, Anadolu Agency reports.
Vucic on Friday said that he has instructed the Serbian Army, the Ministry of Internal Affairs and the Security Information Agency to prepare plans to close Serbia's borders during the migrant crisis.
"If Serbia's national security were threatened, we would close our borders almost hermetically," Vucic told reporters, adding that he hoped that would not happen.
He said Serbia is ready to close its borders within 12 hours and reiterated that he hoped they would not have to do so.
Serbia has had a humanistic attitude towards refugees but the country does not want to be a victim.
"If we were to be the only victim and to think that these should be the countries of the Western Balkans, that would not happen," Vucic said.
Serbia strategically plays an important role as it has borders to EU member states of Croatia and Hungary which asylum seekers choose to enter the EU zone.
Serbia currently hosts 6,000 refugees, according to the Interior Ministry.
Last week, Turkish officials announced they would no longer try to stop asylum-seekers from reaching Europe.
More than 135,000 asylum seekers have crossed to Europe after Turkey opened its borders, accusing the EU of not fulfilling the promises it made as part of a 2016 agreement to share the burden of refugee crisis.
Turkey, which already hosts some 3.7 million Syrian refugees, more than any country in the world, says it cannot absorb another wave of migration.
An escalation in Syria's Idlib has sent a fresh wave of refugees toward Turkey's border.