President Barack Obama will announce on Friday a major overhaul of a controversial National Security Agency program that collects vast amounts of basic telephone call data on foreigners and Americans, a senior Obama administration official said.

In an 11 a.m. (1600 GMT) speech at the Justice Department, Obama will say he is ordering a transition that will significantly change the handling of what is known as the telephone "metadata" program from the way the NSA currently handles it.

Obama's move is aimed at restoring Americans' confidence in U.S. intelligence practices and caps months of reviews by the White House in the wake of damaging disclosures about U.S. surveillance tactics from former U.S. spy agency contractor Edward Snowden.

In a nod to privacy advocates, Obama will say he has decided that the government should not hold the bulk telephone metadata, a decision that could frustrate some intelligence officials.

In addition, he will order that effectively immediately, "we will take steps to modify the program so that a judicial finding is required before we query the database," said the senior official, who revealed details of the speech on condition of anonymity.

While a presidential advisory panel had recommended that the bulk data be controlled by a third party such as the telephone companies, Obama will not offer a specific proposal for who should store the data in the future.

Obama has asked Attorney General Eric Holder and the intelligence community to report back to him before the program comes up for reauthorization on March 28 on how to preserve the necessary capabilities of the program, without the government holding the metadata.

"At the same time, he will consult with the relevant committees in Congress to seek their views," the official said.

Obama is balancing public anger at the disclosure of intrusion into Americans' privacy with his commitment to retain policies he considers critical to protecting the United States.

The official said Obama believes the bulk data program is important to countering terrorist threats but that "we can and should be able to preserve those capabilities while addressing the privacy and civil liberties concerns that are raised by the government holding this meta-data."

People familiar with the administration's deliberations say Obama also is expected to agree to other reforms, such as greatly scaling back spying on foreign leaders and putting a public advocate on the secretive Foreign Intelligence Surveillance Court.

TELEPHONE DATA

But the revelation that the NSA had been collecting vast amounts of telephone metadata on both foreigners and Americans, which had been done in secret for years, became the Snowden disclosure that generated the most heated domestic U.S. political controversy and led to the introduction of conflicting bills in Congress.

The Intelligence committees of both the Senate and House had signaled that they believed current telephone metadata arrangements, under which the data is collected and held by the NSA for five years, should remain in place.

But both the Senate and House Judiciary committees had approved bills that would eliminate domestic metadata collection entirely.

The presidential advisory panel that submitted its recommendations to Obama late last year said collecting telephone metadata, which shows which numbers call which other numbers, and the time and length of calls, should be taken out of NSA control and handed to a third party, such as the phone companies themselves.

Intelligence officials for some time had been circulating secret proposals for having the data stored by phone companies or a non-profit group, and some officials had signaled publicly that NSA might have to accept changes.

Other officials have privately argued that if the system were changed, the NSA should still have instant, direct, online access to the data.

Citing recent breaches of credit card and personal data suffered by Target stores, government officials opposed to changes in the current arrangements for metadata collection argue that the review panel's proposals would make Americans' phone data less, rather than more secure.

Members of the review panel met with top administration officials on Wednesday to discuss the president's speech.

COMBATING TERRORISM

Obama has been under pressure from the intelligence community and key lawmakers to avoid tampering with programs they see as vital to thwarting terrorism plots.

"We believe the program is legal. I am hopeful it's sustained by the president, maybe in slightly different form," said Democratic Senator Dianne Feinstein, chair of the Senate Intelligence Committee and an important voice in the NSA debate.

Snowden leaked secrets about mass collection of telephone data and other secret eavesdropping programs to newspapers before fleeing to Hong Kong and then to Moscow. Journalists with access to Snowden's materials say there are many more disclosures to come.

When the Snowden disclosures first appeared last June, Obama said, "We've struck the right balance" between the desire for information and the need to respect Americans' privacy.

But after a disclosure of U.S. eavesdropping on German Chancellor Angela Merkel's mobile phone, he called for "additional constraints" on American surveillance practices.

Privacy advocates have been appealing for greater protections for Americans' constitutional right to privacy. Some privacy advocates will doubtless be pleased by Obama's plan but other NSA critics may say the president did not go far enough.

"While we welcome the president's acknowledgement that reforms must be made, we warn the president not to expect thunderous applause for cosmetic reforms. We demand more than the illusion of reform," said David Segal, executive director of Demand Progress, a civil liberties advocacy organization.

As well as the tension with Germany, the eavesdropping has disrupted relations with some other nations. Brazilian President Dilma Rousseff postponed a state visit to the United States to express her anger over U.S. intrusions in her country.

(Additional reporting by Patricia Zengerle and Richard Cowan, and Noah Barkin in Berlin; Editing by David Storey and Eric Walsh)