Takhir Ramazanov said the militants - Vadim Butdayev, Imran Myadov, Abdulla Osmanov, and Magomed Salikhov - had been involved in numerous murders and attempted killings, and were also suspected of killing a reporter, Telman Alishayev.
In addition, Salikhov was involved in the 1999 bombing of a residential building that left 64 people dead and injured a further 100 in the city of Buinaksk.
"At around 5:25 p.m. Moscow time [14:25 GMT] police officers stormed an apartment on the third floor of a six-storey residential building in Makhachkala. On entering the apartment they discovered the bodies of four members of an illegal armed group," a ministry spokesman said, adding that the gunfight had lasted several hours.
He said that there were no reported casualties among the police officers.