The recently-formed cell was preparing to carry out “terrorist activities” against the security of the country, the official Saudi Press Agency reported, citing a state security spokesperson.
The spokesperson said the men were killed after they fired shots at security forces, who had surrounded a residential apartment in the Sanabis neighbourhood.
“They were called on to surrender, but they did not respond and opened fire at the security forces … which resulted in their killing,” said the spokesperson.
No civilians or security forces were injured in the operation, he added.
Earlier this year, the Saudi authorities announced they had killed several people after an exchange of fire in Qatif.
According to local media, Saudi security forces besieged the town of Umm al-Hamam in Qatif for more than 15 hours, during which they raided several houses in search of wanted suspects. The Saudi authorities had accused them of committing acts of terrorism in the eastern region.
Saudi Arabia’s Eastern Province – which includes Qatif – has seen bouts of unrest since 2011 when protesters emboldened by the Arab Spring uprisings took to the streets.
The demonstrators have demanded an end to what they say is discrimination by the Sunni-dominated government, a charge Riyadh denies.
One of the leaders of the protest movement, prominent Shia leader and scholar Nimr al-Nimr, was executed in 2016 after he was convicted on terrorism charges.
Nimr’s execution exacerbated sectarian tension both across the Gulf and with Saudi Arabia’s main regional rival, Iran.
The Shia community is estimated to make up between 10 and 15 percent of the kingdom’s population of 32 million, but the government has released no official statistics.
Al Jazeera and news agencies