The Hizmet movement run by US-based cleric Fethullah Gulen, is linked to a network of schools across the world, including in Africa, and the Turkish president is rallying leaders on the continent to help him fight the influence of his longtime rival.
"The party that wants to overthrow me isn't only in Turkey... I am convinced that Tanzania will from now on take measures against this terrorist organisation," Erdogan said after meeting Magufuli.
Turkish officials accuse Gulen of using his vast private education network to build influence and of running a "parallel state" inside Turkey.
Gulen, a former Erdogan ally, vehemently denies the allegations. A reclusive figure, he has lived in self-imposed exile in Pennsylvania since 1999.
Also Read
Hizmet describes itself as promoting Islam through charity efforts and educational work in countries stretching from Turkey to Africa and Central Asia to the United States.
Magufuli said he had asked Erdogan for a loan to help build a planned railway to link Dar es Salaam with neighbouring countries including Rwanda, Uganda and Burundi.
A Turkish firm is set to win a tender to build the USD 7.6 billion (7.1-billion-euro) railway.
The contract had initially been awarded to a consortium of Chinese companies, which had already built five kilometres of the railway.
But it was cancelled due to irregularities in the tender process shortly after Magufuli was elected.
The tender being awarded to a non-Chinese company has cast doubts over whether China's Exim bank, which finances external development projects, will still put up the money.
Disclaimer: No Business Standard Journalist was involved in creation of this content