Mr Erdogan, tackling a corruption scandal that could damage his AK Party at local polls next Sunday, used a speech yesterday also to announce Turkish forces had shot down a Syrian fighter that had crossed into Turkish air space.
Western nations and rights groups have accused Turkey of intolerance for closing down Twitter over anonymously posted audio tapes that implicate Mr Erdogan in corruption.
Mr Erdogan says the tapes had been manipulated as part of a smear campaign.
"I don't care who it is, I'm not listening. Even if the world stands up against us, I am obliged to take measure against every attack that threatens my nation's security.
"This entity called Twitter, this YouTube, this Facebook, they have shaken families to their roots. I don't understand how people of good sense could defend this Facebook, YouTube and Twitter. There are all kinds of lies there."
Mr Erdogan accuses US-based Islamic cleric Fethullah Gulen, a former ally who helped him drive reforms including the taming of the armed forces, of leading a campaign to topple him.