As a general rule, police need a warrant to search the contents of your phone or computer. In Riley v. California (2014) the Supreme Court held unanimously that officers must get a warrant before searching a phone's contents, even when the phone was taken during an otherwise lawful arrest. They may still seize and secure the device at the time of arrest — what they may not do is browse it without a warrant, absent a genuine emergency.
The main exception in practice is not a legal doctrine but a habit: consent. Consent is the most common way police get into a device, and once given it is hard to undo. You can decline. Saying clearly that you do not consent to a search costs nothing and removes the easiest route in. You can also limit consent or withdraw it, though anything already seen cannot be unseen.
Courts have generally treated a passcode as testimonial — something in your mind — so compelling you to disclose it engages the Fifth Amendment privilege against self-incrimination. Police cannot simply demand your passcode. This is not absolute: a judge or grand jury may still order disclosure in some circumstances, and that is precisely the moment to have a lawyer.
Biometrics are treated differently, and the courts disagree with each other. The reasoning is that a fingerprint or a face is a physical characteristic rather than the contents of your mind. In United States v. Payne (2024) the Ninth Circuit held that compelling a fingerprint to unlock a phone did not violate the Fifth Amendment. In United States v. Brown (January 2025) the D.C. Circuit went the other way, reasoning that unlocking by fingerprint can itself communicate that you control the device. The outcome currently depends on where you are.
The practical consequence is straightforward and worth acting on before anything happens:
Border crossings do not follow the ordinary warrant rule, and this catches people out. Under CBP policy, a basic search — an officer looking through the device by hand — may be carried out at a port of entry without a warrant and without any particular suspicion. An advanced search, where equipment is connected to the device to copy or analyse its contents, requires reasonable suspicion of a violation or a national security concern, plus sign-off from a senior manager.
Refusing has different consequences depending on who you are. A US citizen cannot be refused entry for declining to unlock a device, but the device itself may be held. Visa holders and other non-citizens face materially worse outcomes, including being refused entry. If you are crossing a border with sensitive material, the meaningful protection is not to be carrying it.
Legal protections are worth knowing, but they are the second line. Full-disk encryption with a strong passphrase, a device that is powered off rather than merely locked, and not carrying data you do not need are what determine whether a seizure produces anything. The rest of this booklet covers those.