A federal appeals court for the first time ruled Friday that U.S. border agents do not have carte blanche authority to search the cellphones, tablets and laptops of travelers entering the country – a "watershed" decision in the court's own terms and one at odds with the policies of the President Barack Obama administration.

The ruling by a divided 11-judge panel of the 9th U.S. Circuit Court of Appeals is the most significant privacy decision in the digital age following the Supreme Court's ruling last year requiring authorities to get warrants to place GPS tracking devices on suspects' vehicles. Under Friday's ruling, for the first time digital devices are granted limited relief from the so-called "border search exception" of U.S. law that allows international travelers – including U.S. citizens and their luggage and vehicles – to be searched for any reason as they enter the country.

"A person's digital life ought not be hijacked simply by crossing a border. When packing traditional luggage, one is accustomed to deciding what papers to take and what to leave behind," Judge M. Margaret McKeown wrote (.pdf) for the 8-3 court. "When carrying a laptop, tablet or other device, however, removing files unnecessary to an impending trip is an impractical solution given the volume and often intermingled nature of the files. It is also a time-consuming task that may not even effectively erase the files."

In dissent, Judge Milan Smith wrote that the ruling opens the nation's borders "to electronically savvy terrorists and criminals who may hereafter carry their equipment and data across our borders with little fear of detection."

The President George W. Bush administration first authorized the suspicionless, electronics search rules in 2008. The Obama administration followed up with virtually the same rules a year later. Between 2008 and 2010, 6,500 persons had their electronic devices searched along the U.S. border, according to Department of Homeland Security data.

The decision brings to light the friction between the reality that electronic devices have become virtual extensions of ourselves housing everything from e-mail to instant-message chats to photos and our papers and effects — juxtaposed against the government's stated quest for national security.

The DHS's civil rights watchdog, for example, last month reaffirmed the Obama administration's position that travelers along the nation's borders may have their electronics seized and the contents of those devices examined for any reason whatsoever – all in the name of national security.

The San Francisco-based appeals court said that view was too extreme. Under the ruling, border agents may undertake a search of a gadget's content on a whim, just like they could with a suitcase or a vehicle. However, a deeper forensic analysis using software to decrypt password protected files or to locate deleted files now requires "reasonable suspicion" that criminal activity is afoot. The court left rules intact that a "manual review of files on an electronic device" may be undertaken without justification.

"The nature of the contents of electronic devices differs from that of luggage as well. Laptop computers, iPads and the like are simultaneously offices and personal diaries. They contain the most intimate details of our lives: financial records, confidential business documents, medical records and private emails," McKeown said.

The case concerned a California man who, in 2007, crossed the border from Mexico at the port of entry in Lukeville, Arizona. He was immediately flagged by border agents because he was convicted of child molestation and other charges years earlier.

The authorities searched his two laptops and three digital cameras, finding family pictures and other harmless photos.

But agents took his devices to Tucson, some 170 miles away, to perform forensic analyses. Dozens of child pornography pictures were discovered that defendant Howard Cotterman allegedly deleted or had stored in encrypted, password-protected folders.

A federal judge had tossed the evidence, saying the authorities lost the right to examine the gadgets because they removed them from the border area. A three-judge panel of the same circuit ruled in 2011 that taking the gadgets to Tucson didn't matter, and reinstated the evidence.

But the nation's largest appeals court agreed to rehear the case with 11 judges. In Friday's ruling, the majority concluded that it did not matter that the gadgets were ferried to Tucson. Instead, what mattered was whether the government had a willy-nilly rationale to perform a forensic analysis on them.

The court noted that no reason was needed to manually inspect the content of a gadget. But a forensic examination required a "reasonable suspicion."

While the decision seemingly bolsters the digital rights of travelers, the court's pronouncement of reasonable suspicion did not sit well with Michael Price, the counsel for the Liberty & National Security Program of the Brennan Center for Justice at New York University.

The court found enough "reasonable suspicion" based on the facts that Cotterman was a convicted sex offender and frequently traveled to Mexico, a known destination for sex tourism. What's more, adding to reasonable suspicion, under what the court labeled as the "totality of the circumstances," was the fact that some of the files on one of the laptops were password protected.

"We really didn't think there was any reasonable suspicion for the forensic examination," Price said.

Still, he added that the decision was a good one overall in the digital age.

"This rule is really designed for electronic border searches and the fundamental difference between our briefcase and your laptop: The idea that you can hold your entire life in your laptop, not your briefcase," he said. "That is something the 9th Circuit is saying is recognized by the Fourth Amendment."

Smith, who wrote the dissent, said the government should always be allowed to forensically examine seized gadgets at the border, regardless of how reasonable suspicion is defined.