The tweet referred to the 1967-70 Nigerian Civil War and to treating “those misbehaving today” in “the language they will understand”.

It follows a recent spate of attacks on offices, mainly in the south-east, blamed on regional secessionists.

Nigeria’s information minister called Twitter’s move unfair, labelling it “double standards”.

The BBC’s Joshua Ajayi in Lagos says this is the first time a tweet from the president has been deleted.

The tweet, posted on Tuesday, read: “Many of those misbehaving today are too young to be aware of the destruction and loss of lives that occurred during the Nigerian Civil War. Those of us in the fields for 30 months, who went through the war, will treat them in the language they understand.”

A Twitter spokesperson said the post “was in violation of the Twitter Rules. The account owner will be required to delete the violative Tweet and spend 12 hours with their account in read-only mode”. The statement gave no further details.

Mr Buhari’s Twitter account on Wednesday afternoon still noted that one tweet was “no longer available”.

However, the account had also re-tweeted a video from the president, along with the quote: “Whoever wants the destruction of the system will soon have the shock of their lives. We’ve given them enough time… we will treat them in the language they understand.”

Mr Buhari made no mention of any particular group in his tweet.

Authorities have accused banned separatists of attacks, including arson, on electoral offices and police stations in the south-east of Nigeria in recent weeks.

Our correspondent, Joshua Ajayi, says many people were angry on social media over the tone of the language used by the president, which they believed was much stronger than he had used in his condemnation of acts of banditry or attacks by Boko Haram militants in the north.

The Nigerian Civil War, or Biafran War, was fought over an attempted breakaway by the state of Biafra. The 30-month conflict led to the defeat of the secessionist forces with more than a million people killed, mostly civilians through starvation.