Many of the protesters chanted anti-American slogans, like "down with Obama" and "down with foreign forces," during the hours-long protest.
Isaf said the men had been involved in roadside bomb attacks, and that Nato and Afghan soldiers were fired upon from "multiple directions" as they entered the compound.
Routine civilian casualties
The protest mirrored a similar demonstration last week, when Nato and Afghan forces raided a house in Wardak province. Neighbours claimed the night raid killed three civilians, and hundreds of them took to the streets to protest the following afternoon.
Afghans have staged a number of similar protests in recent months: Villagers near Jalalabad burned tyres in May after a night raid killed at least nine people, and hundreds protested after Nato troops opened fire on a bus in Kandahar in April.
General Stanley McChrystal, the former commander of Nato forces in Afghanistan, issued a classified directive earlier this year calling on troops to limit their use of night raids, which routinely result in civilian casualties.
A United Nations report released last week found that raids by Nato troops killed 41 civilians in the first half of 2010.
Night raids have been a particular point of friction between Nato and Hamid Karzai, the Afghan president. Karzai demanded an end to all night raids in February.