A leaked document has revealed the monumental scope of the government’s surveillance of Americans’ phone records — hundreds of millions of calls — in the first hard evidence of a massive data collection program aimed at combating terrorism under powers granted by Congress after the 9/11 attacks.

At issue is a court order, first disclosed late Wednesday by the Guardian newspaper in Britain, that requires the communications company Verizon to turn over on an “ongoing, daily basis” the records of all landline and mobile telephone calls of its customers, both within the U.S. and between the U.S. and other countries.

Intelligence experts said the government, though not listening in on calls, would be looking for patterns that could lead to terrorists — and that there was every reason to believe similar orders were in place for other phone companies.

Some critics in Congress, as well as civil liberties advocates, declared that the sweeping nature of the National Security Agency program disclosed Thursday represented an unwarranted intrusion into Americans’ private lives.

But a number of lawmakers lauded the program’s effectiveness. Leaders of the House Intelligence Committee said the program had helped thwart at least one attempted terrorist attack in the United States, “possibly saving American lives.”

Separately, the Washington Post and the Guardian reported late Thursday the existence of another program used by the NSA and FBI that scours the nation’s main Internet companies, extracting audio, video, photographs, emails, documents and connection logs to help analysts track a person’s movements and contacts. It was not clear whether the program, called PRISM, targets known suspects or broadly collects data from other Americans.

The companies include Microsoft, Yahoo, Google, Facebook, PalTalk, AOL, Skype, YouTube and Apple.

One outraged senator, Ron Wyden, D-Ore., said of the phone-records collecting: “When law-abiding Americans make phone calls, who they call, when they call and where they call is private information. As a result of the discussion that came to light today, now we’re going to have a real debate.”

But Sen. Lindsay Graham, R-S.C., said Americans have no cause for concern. “If you’re not getting a call from a terrorist organization, you’ve got nothing to worry about,” he said.

Senate Intelligence Committee Chairwoman Dianne Feinstein, D-Calif., said the order was a three-month renewal of an ongoing practice that is supervised by federal judges who balance efforts to protect the country from terror attacks against the need to safeguard Americans’ privacy.

Officials say the surveillance powers are granted under the post-9/11 Patriot Act, which was renewed in 2006 and again in 2011.But Rep. Jim Sensenbrenner, R-Wis., who sponsored the act, said he was “extremely troubled by the FBI’s interpretation of this legislation.”

While the scale of the program might not have been news to some congressional leaders, the disclosure offered a public glimpse into a program whose scope is not widely understood. Sen. Mark Udall, a Colorado Democrat who serves on the Intelligence Committee, said it was the type of surveillance that “I have long said would shock the public if they knew about it.”

The government has hardly been forthcoming.

Wyden released a video of himself pressing Director of National Intelligence James Clapper on the matter during a Senate hearing in March.

“Does the NSA collect any type of data at all on millions or hundreds of millions of Americans?” Wyden asked.

“No, sir,” Clapper answered.

“It does not?” Wyden pressed.

Clapper quickly softened his answer. “Not wittingly,” he said. “There are cases where they could, inadvertently perhaps, collect — but not wittingly.”

There was no immediate comment from Clapper’s office Thursday on his testimony in March.

The public is now on notice that the government has been collecting data — even if not listening to the conversations — on every phone call every American makes, a program that has operated in the shadows for years, under President George W. Bush, and continued by President Barack Obama.

Without confirming the authenticity of the court order, White House spokesman Josh Earnest said such surveillance powers are “a critical tool in protecting the nation from terror threats” by helping officials determine whether people in the United States who may have been engaged in terrorist activities have been in touch with other known or suspected terrorists.

House Intelligence Committee Chairman Mike Rogers, R-Mich., stressed that phone records are collected under court orders that are approved by the Senate and House Intelligence committees and regularly reviewed.

But privacy advocates said the scope of the program was indefensible.

“This confirms our worst fears,” said Alexander Abdo, a staff attorney with the American Civil Liberties Union’s National Security Project. “If the government can track who we call,” he said, “the right to privacy has not just been compromised — it has been defeated.”