Egyptian authorities have arrested a retired general after denying him permission to run in presidential elections in March.

Sami Anan was the last challenger seen as a potential threat to President Abdel Fatah al-Sisi, himself a former military chief, whose re-election is considered almost certain.

The arrest of Anan, a former member of Egypt’s supreme military council for armed forces (Scaf), appears to be a calculated move to push him out of the race. Earlier a declaration by the military accused him of election violations and said he would be “summoned for interrogation in front of specialised personnel”.

Timeline After Tahrir Square Show Egyptian president Hosni Mubarak steps down after almost 30 years in power amid anti-government Arab spring protests. Rallies continue all year. Islamist parties win drawn-out parliamentary elections. Mohamed Morsi of Muslim Brotherhood wins presidential election. Mubarak sentenced to life in prison for complicity in killing 800 protesters in 2011. Army overthrows Morsi. Security forces kill hundreds in pro-Morsi camp. Former army chief Abdel Fatah al-Sisi wins presidential election. Morsi sentenced to death. Egypt's appeal court orders retrial in 2016. Isis claims responsibility for bombing Russian plane in Sinai. Crew and 224 tourists killed. IMF approves three-year $12bn loan to Egypt designed to help country out of economic crisis. Suicide bombers kill dozens at two churches as worshippers celebrate Palm Sunday. Egyptian airstrikes on northern Sinai after militants assault on a mosque kills 305 people. Sisi announces he will run for a second term. Sisi wins snap Egyptian referendum amid vote-buying claims. It could keep him in power until 2030. Mohamed Morsi, ousted president of Egypt, dies in court. Hosni Mubarak dies at 91.

Mahmoud Refaat, a spokesman for Anan’s campaign abroad, said: “I hold the regime of Abdel Fatah al-Sisi entirely responsible for his wellbeing. Yesterday 30 members of campaign were also arrested as well as some of their family members. It’s not known where any of them are being held.”

Anan is the second former high-ranking official to be prevented from running against Sisi, who declared he would run for a second term late last week.

The president has led a crackdown on dissidents while attempting to enact tough economic reforms tied to a $12bn (£8.6bn) International Monetary Fund loan.

Anan previously stated he wished to save Egypt from “wrong policies”, and was seen as a favourite to challenge Sisi on the campaign trail, even attracting support from members of the banned Islamist group the Muslim Brotherhood. He later made the controversial choice to appoint the country’s former top auditor Hisham Geneina as one of his two running mates. Geneina was sentenced to a year in prison in 2016 after accusing the Egyptian government of rampant corruption costing the country billions of dollars.

Anan headed the Scaf from 2005, including during a period of military rule after the 2011 revolution that toppled Hosni Mubarak. He was fired in 2012 by the then president Mohamed Morsi, coinciding with Sisi’s appointment as defence minister. Morsi was toppled in a 2013 military coup which put Sisi in power. Sisi then won 97% of the vote in elections in 2014.

The Egyptian military general command said in a statement on Tuesday that it could not “turn a blind eye to the legal violations” by Anan. It said he would be interrogated on charges of running for election without prior approval from the military, forging documents stating that he had left the military and “inciting against the armed forces”.

Refaat said: “The declaration made by the army today was made by Sisi’s office, not by the real army. It’s pure lies … Mr Anan was the strongest candidate and the true first choice of Egyptians, so the regime arrested him.”

Anan’s arrest follows the aborted candidacy of the former prime minister Ahmed Shafiq, previously the primary challenger to Sisi. Shafiq was deported from the United Arab Emirates after declaring his intention to run, and held incommunicado for 24 hours. He withdrew from the race at the beginning of January, saying that he was not “the ideal person to lead the state’s affairs”.

Mohamed Anwar al-Sadat, the nephew of Egypt’s former president, declined to run last week, citing a political environment hostile to “genuine competition” and fearing attacks on his supporters.

Khaled Ali, a leftist lawyer, has said he still intends to compete, despite an ongoing court case accusing him of making an obscene gesture during celebrations outside a Cairo court. Ali will hear on 7 March, two weeks before the election, whether his appeal has been accepted and he is able to compete.

Another potential contender is Mortada Mansour, a rightwing firebrand MP, who has until 29 January to obtain the 25,000 nominations from 15 governorates necessary to get on the ballot.

The Sadat, Ali and Anan campaigns have said they routinely experienced interference or intimidation. Anan and Sadat’s teams said their supporters faced problems at local offices when attempting to register the pledges needed for candidates to get on the ballot.