National Police spokesman Boy Rafli Amar said one of the captured men, Zainal Anshori, was a senior figure in Jemaah Anshorut Daulah, a network of Indonesian extremists that claims allegiance to the Islamic State group.
Police fatally shot a militant from the same group last month and arrested seven others.
Amar said Anshori and the two other militants were planning to attack a police station in East Java's Lamongan district next week.
Muslim-majority Indonesia has carried out a sustained crackdown on militants since the 2002 Bali bombings by al-Qaida-affiliated radicals that killed 202 people.
Amar said the three men planned to stage a gun attack on the police station, using the remaining weapons from a cache that the group obtained from the southern Philippines in 2015.
Some of those weapons were used in the January 2016 suicide bombing and gun attack in central Jakarta that killed four civilians and four attackers.