A High Court judge has referred an attempt by campaigners to force an investigation into Facebook's alleged sharing of data from EU users with the US National Security Agency to the European Court of Justice.

Justice Gerard Hogan upheld an earlier decision by Data Protection Commissioner Billy Hawkes to refuse to investigate.

Austrian law student Max Schrems had sought a judicial review of a decision by Mr Hawkes not to investigate a complaint he had made against Facebook.

Mr Schrems raised concerns about the transfer of Facebook users' data to the US where it was being used in the NSA's Prism surveillance programme.

The judge referred a number of questions to the European Court of Justice, saying the case would stand adjourned until those matters are addressed. 

The High Court has jurisdiction because Facebook's European headquarters are based in Dublin.

Ahead of the hearing, the campaign group europe-v-facebook indicated it planned to appeal any such decision. 

The judicial review centred on whether Mr Hawkes had correctly interpreted the Safe Harbour agreement between the US and EU of July 2000.

It permits the transfer of certain types of data.

Justice Hogan noted that the agreement had been struck before the advent of social media and before the attacks of 11 September .

Justice Hogan said he proposed to ask the Court of Justice whether an independent office holder may conduct an investigation in light of “factual developments” since the agreement of 2000.

He said the Safe Harbour agreement may be reflective of a more "innocent age".

He said if it was the case that Mr Hawkes could not “look beyond” Safe Harbour then the application by Mr Schrems must fail.

However, he said he was referring this question to the ECJ.

Mr Hawkes said the ruling backs his position that the issues raised by Mr Schrems are undoubtedly serious and focus on wider issues of European law.

"The commissioner acknowledges and accepts the court's view that, because the data privacy issues raised by the Snowden revelations are so serious, it is appropriate that the European Court of Justice should be asked to consider the critical issue," his office said in a statement.

"The commissioner looks forward to participating in that process in due course."