Pakistan has restored access to Twitter after blocking the popular social networking site over the posting of content it deemed an affront to Muslims, Pakistan's telecom authority said Monday.

Mohammed Younis, the authority's director of public relations, said Twitter was blocked on Sunday morning because of "some material considered to be offensive to the Muslim community," but access was restored by Sunday evening.

A spokesperson for Pakistan's Ministry of Information Technology told CNN that Twitter was blocked because the site did not remove links and references to a competition taking place on Facebook to post images of the Muslim prophet Mohammed.

"The government is in contact with Twitter and had asked them to remove the material. When they didn't, it was decided that the site would be blocked," said ministry spokesman Naveed Ahmed.

Pakistan blocked Facebook in May 2010 in response to a similar contest that called on people to draw depictions of Mohammed.

Acid attacks on the rise in Pakistan

MUST WATCH

JUST WATCHED

What Pakistanis want from the U.S.

MUST WATCH

The "Everybody Draw Mohammed Day" Facebook page offended many Pakistanis as Islam discourages any visual representation of God or prophets like Mohammed.

Younis said it was the IT ministry's decision to reverse the ban but he could not confirm whether Twitter had removed the tweets deemed offensive.

However, he said Facebook had responded to requests to remove controversial content in Sunday's case. No-one from the ministry or Twitter was available for comment.

Facebook confirmed that it had restricted access to some content on its site in Pakistan after a request from the authorities.

"While we do not remove this type of content from the site entirely unless it violates our Statement of Rights and responsibilities, out of respect for local laws, traditions and cultures, we may occasionally restrict its visibility in the countries where it is illegal, as we have done in this case," Facebook said in an emailed statement.

Twitter is hugely popular in Pakistan, with a reported six million account holders, including public figures such as politicians, singers and sports stars. Exiled former president Pervez Musharraf is on Twitter, as is Imran Khan, the cricketer turned politician.

It seemed many users were able to get around Sunday's outage.

"The fact that despite their 'Twitter Ban', we are still tweeting from Pakistan, should tell them how stupid it is to censor internet," tweeted Marvi Sirmed, a Pakistani columnist and human rights activist with 21,973 followers.