The ruling military government said that the men had been in contact with Taya in Qatar, where he lives in exile after being overthrown last August in a bloodless coup, and were plotting to derail a return to democracy in the Islamic Republic.
Sidi Ould Domane, spokesman for the head of the 17-member military council, said: "A group of people nostalgic for the past are trying to impede the process of democratisation that is under way. They want to sabotage Sunday's referendum."
The coup ended two decades of authoritarian rule by Taya, winning widespread support and bringing residents on to the streets.
The military council installed a civilian interim government and pledged a brief transition leading to presidential polls. Part of the process is a referendum, due on Sunday, on changes to the constitution.
Shortly before taking up an asylum offer in the Gulf Arab state of Qatar, Taya urged soldiers to resist the country's new leadership and vowed to return, though his words were not taken seriously by many residents or officials in the capital, Nouakchott.
The men arrested - who included the former head of the navy, his businessman son, a former ambassador to the United Nations and a former senior army official - had remained in contact with Taya since his ousting, officials said.
The referendum will be followed by presidential polls due in March 2007, five months ahead of the timetable the government originally set after taking power.
The referendum will be the first vote in Mauritania since the coup and the beginning of a process which also includes legislative elections in November and senatorial polls in January.
Western nations and other African leaders initially condemned the seizure of power last August but have said they will support the military rulers if they live up to their promise of organising free and fair elections.