The court in the central Serbian town of Kraljevo freed the officers as tensions escalated between the Balkan foes and following US and European Union demands that they be set free.
All three are being allowed to return to Kosovo and it is not clear if the case will continue in their absence.
The officers were detained in mid-June. Serbia said they had crossed into the country from Kosovo, while Kosovar authorities insisted they had been kidnapped inside Kosovo and transferred to a Serbian prison.
In a tweet, Kosovo Prime Minister Albin Kurti confirmed the officers’ release but while welcoming the news insisted Serbia be held accountable.
The dispute has increased tensions between the two countries that have flared into recent violent clashes in the Serb-majority north of Kosovo, stirring fears of a renewal of the 1998-99 conflict that left more than 10,000 people dead, mostly Kosovar Albanians.
In May, Kosovo police seized local municipality buildings in northern Kosovo, where Serbs represent a majority, to install ethnic Albanian mayors who were elected in a local election in April that Serbs overwhelmingly boycotted.
Last week the EU summoned the leaders of Kosovo and Serbia to Brussels in a bid to ease the tensions. The meeting produced no breakthrough as EU officials urged both sides to make an immediate effort to defuse the situation.
Serbia and its former province Kosovo have been at odds for decades, with Belgrade refusing to recognise Kosovo’s 2008 declaration of independence.