The interior ministry blamed an Al-Qaeda-linked group for one attack and said "terrorists" -- the term it uses for jihadists -- were involved in the second.
In the first clash in central Tunisia, three policemen and a jihadist were killed when national guardsmen, acting on a tip-off, tried to ambush two armed men who were allegedly planning attacks, it said.
"The national guard attempted to ambush at dawn two terrorists on a motocycle in Sidi Ali Ben Aoun after obtaining information that (they) were about to launch an operation," ministry spokesman Mohamed Ali Aroui told AFP.
They were pursued by an elite unit of the national guard, Aroui said.
Also Read
"One of the terrorists was exterminated, the second was wounded and arrested. He is in a serious condition," he added.
Twelve people were wounded, including three members of the security forces, a soldier and eight bystanders, an official at the nearby Sidi Bouzid hospital told AFP.
One civilian was in a critical condition, the official added.
The interior ministry blamed the violence on Tunisia's main jihadist group, the Al-Qaeda-linked Okba Ibn Nafaa Brigades which it has accused of being behind several recent attacks.
Authorities have blamed the group for a series of attacks, including the March massacre at the Bardo National Museum in Tunis that killed 21 foreign tourists and a policeman although the Islamic State group had claimed responsibility for the museum killings.
In the second incident on Monday, a Tunisian policeman was killed and four wounded in clashes with jihadists on the border with Algeria, Aroui said.
"A national guardsman was martyred and four others wounded in Jendouba region on the border with Algeria during a shoot-out with a terrorist group," Aroui told AFP.
The Tunisian army has been battling militants in the rugged Mount Chaambi region near the border with Algeria since 2012.
Tunisia has seen a surge in radical Islam since veteran president Zine El Abidine Ben Ali was ousted in the 2011 revolution.