The victims were identified as Sub-inspector of Sadar Police Station, Soikat Hossain Sunny, SI Mahmudul Hasan, SI Mohammad Khairul Hossain, ASI Saiful Islam and Constable Maruf Hawladar.
The incident took place at the Shikdar Bari in the area.
Also read: 13 cops injured in clash with fishermen in Chandpur
Hayatul Islam Khan, superintendent of Pirojpur Police, said a team of police conducted a drive in Kumarkhali area for arresting an accused Hasan Shikdar of a criminal case in the dead of night.
When police was heading towards Sadar Police Station with the accused Hasan, the relatives of the accused and local people attacked on police in a bid to snatch away the accused from police custody.
Also read: Accused criminal killed in gunfight, 7 cops injured in Chattogram
Seven people including three sub-inspectors, one assistant sub-inspector and a constable were injured during the attack.
Police arrested seven people in connection with the attack on police. Hasan Shikdar, son of Anwar Shikdar, Shaon Das, son of Mithu Das were among the arrestees.
The injured were taken to local hospital where three were given first aid.
Also read: 6 policemen injured in Sylhet anti-drug drive
Nurul Islam Badal, officer-in-charge of Sadar Police station, said police will file a case in this connection.