The government has argued that under a 1979 Supreme Court ruling, Smith v. Maryland, no one has an expectation of privacy in the telephone data that phone companies keep as business records. In that ruling, the high court rejected the claim that police needed a warrant to obtain such records.
But Leon said that was a "far cry" from the issue in this case.
"The almost-Orwellian technology that enables the government to store and analyze the phone metadata of every telephone user in the United States is unlike anything that could have been conceived of in 1979," he wrote.
Associated Press writers Mark Sherman, Pete Yost, Nedra Pickler and Kimberly Dozier in Washington and Bradley Brooks in Brazil contributed to this report.
Follow Fred Frommer on Twitter: http://twitter.com/ffrommer