Tunisia's president has called for Prime Minister Youssef Chahed to step down or seek a vote of confidence if the country's political and economic crisis continues, withdrawing his support for the premier, who has clashed with the president's son.

President Beji Caid Essebsi's son, Hafedh Caid Essebsi, who is leader of the ruling Nidaa Tounes party, called for Chahed's dismissal in May because of his government's failure to revive the economy. His call was supported by the powerful UGTT union, which rejected economic reforms proposed by the prime minister.

"There is a difference between the parties and national organisations about the government, between government and key players like UGTT and some parties," Essebsi said on Sunday in an interview broadcast by local Nesma TV.

"If this situation continues, the prime minister must resign or go to the parliament to ask for confidence," he said.

This is the latest punch thrown in an ongoing battle within Essebsi's Nidaa Tounes party.

Chahed, who was appointed by Essebsi in 2016, has accused the president's son of destroying Nidaa Tounes, and said the crisis in the party has affected state institutions.

The Ennahda party has said the exit of the prime minister would hit stability at a time when the country needed economic reforms.

Tunisia has been hailed as the Arab Spring's only democratic success because protests toppled autocrat Zine El Abidine Ben Ali in 2011 without triggering violent upheaval, as happened in Syria and Libya.

But since then nine cabinets have failed to resolve economic problems including high inflation and unemployment, and impatience is rising among lenders such as the International Monetary Fund, which have kept the country afloat.

Seven prime ministers have failed to fix a sluggish economy. Turmoil and militant attacks have deterred investors and tourists, eroding living standards of ordinary people and causing an increase in unemployment.

Annual inflation hit a record high of 7.8 percent in June as the dinar currency tanked, making food imports more expensive.