The order was given at a security meeting presided over by President Muhammadu Buhari at the presidential villa in Abuja.
Mansur Dan Ali, minister of defence, had described the trend of hate speech on social media as worrisome.
“Relevant security agencies should as a matter of urgency tackle the propagation of hate speeches through the social media, particularly by some notable Nigerians,” Ali said.
The development comes one year after Lai Mohammed, minister of information, vowed that the current administration would not regulate social media.
“We have said it before and we want to re-state it: the federal government has no immediate or long-term plan to stifle press freedom. Even the social media, with its warts and all, will neither be regulated nor have its operations tampered with,” he had said in January 2017.