ISTANBUL — Under pressure from its Western allies to do more to combat Islamist extremists, the Turkish authorities arrested 21 suspected Islamic State members on Friday, the semiofficial Anatolian News Agency reported.

Among those arrested were three foreigners and two prominent Islamic State supporters known to have recruited fighters in Turkey, the local news media reported.

In early-morning raids in Istanbul and Sanliurfa Province, which borders Syria, the Turkish police seized automatic rifles, large ammunition packs and military uniforms, the agency reported.

Turkey is a NATO member and a longtime American ally, but it has been frequently criticized for its reluctance to play a more active role in combating the Islamic State. Western officials have accused Turkey of a degree of ambivalence toward the militant group, which now controls large parts of Syria and Iraq, and the Turks sometimes give the impression that they see Kurdish autonomy in Syria as a greater threat to their country than the extremists.