One of the escapees was Saleck Ould Cheikh, who had been on death row since 2011 for his part in a plot to assassinate former Mauritanian president Mohamed Ould Abdel Aziz, but it was unclear if he was among the fatalities.
Three escaped prisoners have been killed in Mauritania during an operation to recapture them, according to the government.
A police officer died and a fourth prisoner was detained, officials said on Saturday.
The operation took place overnight on Friday in the heartland desert area of Adrar, a security official said on condition of anonymity.
The four prisoners had escaped from a Nouakchott prison the previous Sunday.
The interior ministry has said two guards were killed and two injured during the breakout, which was a rare event in a nation spared the insurgency sweeping through the Sahel region.
According to a military official, two of the prisoners had been sentenced to death, while the other two were awaiting trial for membership in a terrorist organisation.
The same source said one of the prisoners was Saleck Ould Cheikh, who had been on death row since 2011 for his part in a plot to assassinate former Mauritanian president Mohamed Ould Abdel Aziz.
Ould Cheikh had already escaped prison in December 2015 before being arrested in Guinea Bissau and sent back to Mauritania after three weeks on the run.
The report was unclear whether Ould Cheikh was among the fatalities or the fourth prisoner who was recaptured.
The second prisoner on death row participated in attacks on the army in the north of the country in 2005, the military official said.
He said their vehicle had been found in the northeastern part of Nouakchott.
Security forces "came under heavy fire which led them to engage in combat with the terrorist elements", the defence and interior ministries said.
READ MORE: Mauritania's ex-leader faces political corruption charges in landmark trial
The death penalty has not been enforced in Mauritania since 1987.
With a population of 4.5 million, Mauritania has been spared terrorist attacks since 2011, despite sharing a border with Mali, from where an insurgency that began in 2012 has spread across the region.
The absence of attacks has fuelled suggestions a secret non-aggression pact exists between Nouakchott and the armed groups.
Washington claimed to have found documents in 2011 at the Pakistani hideout where former Al Qaeda leader Osama bin Laden was killed, listing an attempt at rapprochement between the group and the Mauritanian government in 2010.
The government refutes this.
Mauritania was regularly targeted in the 2000s, including attacks and kidnappings.
Abdel Aziz, the former head of presidential security, came to power in a coup in 2008 and a year later was elected president.
Any qualms Western countries had about his rise were set aside.
READ MORE: Frightened Africans flee Tunisia after president's anti-migrant tirade