The US government and leading internet companies have agreed to a compromise allowing companies to reveal how often they are ordered to turn over information about their customers in national security investigations.

The Justice Department announced the deal on Monday with Google, Microsoft, Yahoo, Facebook and LinkedIn.

Other companies are expected to participate once it is approved by the Foreign Intelligence Surveillance Court.

Attorney General Eric Holder and Director of National Intelligence James Clapper said communications providers would be allowed to disclose figures on consumer accounts requested.

"The administration is acting to allow more detailed disclosures about the number of national security orders and requests issued to communications providers," they said, in a joint statement.

Companies wanted to make the disclosures to alleviate public speculation about their cooperation with the government.

The government opposed the companies' request, saying it could interfere with national security investigations.

The reporting will be in very general terms. Companies will have to wait six months before releasing information about intelligence orders.