Your phone could cost you entry to the US. Being denied entry to the US as a legal immigrant or visa holder is becoming increasingly common — and increasingly concerning. The Trump administration is tightening control on immigration and its definition of political dissent, with reports of Customs and Border Protection (CBP) agents ramping up digital inspections of travelers’ cellphones, The Verge reports. With the consequences growing more severe, the best protection for now may lie in minimizing what’s accessible on your device.

(Tap or click the headline above to read this story with all of the links to external sources.)

Multiple cases in point: A doctor on an H-1B visa was deported to Lebanon after CBP officers found “sympathetic media” of Hezbollah leaders on her phone, CNN reports. Similarly, a French scientist was denied entry after agents flagged messages criticizing Trump’s research cuts, the Guardian wrote. Columbia University graduate student and permanent US resident Mahmoud Khalil was also detained by the Department of Homeland Security over allegations that he “led activities aligned to Hamas,” and is still being detained despite no criminal charges being leveled against him.

How often do US border agents search phones? While CBP says digital searches remain rare — accounting for less than 0.01% of international arrivals — they’re becoming more frequent, with agents conducting some 47.1k device inspections in FY2024, more than doubling over the course of a decade.

What border agents are allowed to do: The Fourth Amendment of the US — which protects against unreasonable searches and seizures — doesn’t fully apply at the border, meaning that officers can search your phone, laptop, or other devices at airports and entry points without a warrant — even if you hold a visa of permanent residency. These checks come in two forms: basic searches, where agents scroll through your downloaded or cached content (but should not be permitted to search information and media only available on the cloud), and forensic searches, which involve extracting data using special tools. The latter typically requires a higher level of suspicion, but still doesn’t necessarily need a warrant if you’re at the border.

Your rights depend on your immigration status — and where you land: US citizens can’t be denied reentry for refusing to unlock their phones, but CBP can still take their devices. Permanent residents have similar protections, though spending more than 180 days outside the US allows agents to regard the entrants as new applicants for admission and judge their eligibility to enter at their discretion. Courts in New York have blocked warrantless searches entirely, but in jurisdictions like Texas and Virginia, they’re still permitted — meaning your rights can vary dramatically depending on the airport you land in. Visa holders (whether tourist or student) have the least leeway — saying no to a search can mean deportation on the spot.

How to protect your data if you’re crossing the border: “We always encourage data minimization when crossing the border; you want to travel with the least amount of data possible,” said Saira Hussain, senior staff attorney at the Electronic Frontier Foundation (EFF), which means that encrypting your device and using strong passwords can be good protective measures. Courts have ruled that officers can’t force you to hand over a password — but in many places, they can make you unlock your device using other login options, making it important to disable biometric logins like Face ID or fingerprint recognition.

It’s reached the point where extreme measures are recommended: The EEF suggests backing up your data to the cloud and wiping your device before travel, deleting all information off your phone, including information and media the “recently deleted” folder, which border agents can legally access.