Twitter has blocked US intelligence agencies from using a key analytics service, which parses through the social network's millions of tweets in real-time, for the purpose of surveillance, the Wall Street reported. The move, which has not been publicly announced, was reportedly confirmed by a senior US intelligence official and other people familiar with the matter.

Dataminr, a private company that sifts through public Twitter feeds for clients, analyses the network's postings in real time and sends out alerts of terror attacks, political unrest and other breaking news events unfolding around the world. It also analyses geographic data, market information and other data to determine whether the information is credible.

Twitter owns about 5% stake in Dataminr – the only company it authorises to access a real-time feed of every public tweet on its network and then sell that information to other clients.

US intelligence agencies reportedly got access to the firm's service when the CIA's venture capital firm, In-Q-Tel, invested in several tech firms, including Dataminr, to further its online monitoring efforts.

The social media giant, however, has a policy banning third-party companies from selling information to government agencies for the purpose of surveillance. After the pilot programme arranged by In-Q-Tel ended recently, Twitter reportedly told Dataminr that it did not want them to continue providing the service to the spy agencies.

"Dataminr uses public Tweets to sell breaking news alerts to media organizations such as CNN and government agencies such as the World Health Organization, for non-surveillance purposes," Twitter told IBTimes UK. "We have never authorized Dataminr or any third party to sell data to a government or intelligence agency for surveillance purposes. This is a longstanding policy, not a new development."

A senior intelligence official said Twitter is concerned about the "optics" and appearing too close to the US intelligence services.

In a statement to the Wall Street Journal, Twitter said its data is "largely public and the US government may review public accounts on its own, like any user could."

Dataminr will continue to provide its services to the financial industry, news media and other clients outside the intelligence community. It also has a separate $225,000 contract to provide its service to the Department of Homeland Security.

In March, the New York-based company said its service first notified clients about the Brussels attacks 10 minutes before news media picked it up. In 2013, the service was used by the Presidential Inauguration Committee to track any potential threats during US President Barack Obama's second presidential inauguration ceremony. It also alerted the agencies about the Paris terror attacks shortly after they took place in November, besides providing other alerts on Islamic State (Isis) attacks in Libya and the political crisis in Brazil.

"If Twitter continues to sell this [data] to the private sector, but denies the government, that's hypocritical," former deputy director of the National Security Agency (NSA) John Inglis said. "I think it's a bad sign of a lack of appropriate cooperation between a private-sector organization and the government."

The move is the latest clash between tech companies and the government over the highly debated issue of user privacy versus security concerns. The FBI and Apple were recently locked in a legal showdown for months over demands to unlock an iPhone used by one of the shooters in the San Bernardino shooting in December. The FBI eventually dropped the suit after spending $1.3m (£900,000) on a third-party hack to access the phone.

"The volume of the group's activity on Twitter yields a vast amount of data that is a crucial tool for counterterrorism practitioners working to manage threats," said Michael S Smith II, chief operating officer of the security consulting firm Kronos Advisory. "Twitter's decision could have grave consequences."