Two suspected thugs were on Tuesday fatally shot in Ruaka, Kiambu county.
According to the police, the suspects who were riding on a motorcycle were planning to rob a supermarket when the officers pounced on them.
The suspects who had on their persons a firearm believed to belong to the police are said to have fired shots at the police who retaliated leaving the duo dead and an officer from Nairobi with a gunshot wound to the neck.
The injured officer is receiving treatment at Uzima Hospital within the city. He is in stable condition.
Gigiri police boss Alice Kimeli said the suspects were planning a robbery when police received word.
“In the process of stopping the gang, a shootout broke out and we have casualties on the side of the suspects while one officer was injured,” she said.
The crime scene has since been processed and the bodies moved to the mortuary as the police seek to establish whether there were others involved.
They are also seeking to establish the ownership of the firearm and if it had been used elsewhere.
Security has been heightened around the city ahead of the Christmas holiday.