THE SHORT ANSWER
No. iPhone has one device passcode, and there is no second code that wipes or hides your data when you enter it. You can quickly make your iPhone require its passcode instead of Face ID, and you can have it erase itself after 10 failed attempts. Some apps add a duress option for the files they hold.
People usually search for this when they’re worried about being made to unlock their phone: by a partner, at a border, or after a theft. Those situations need different answers, and a code that deletes things is only sometimes the right one.
01 / THE IDEA
What a duress password is.
A duress password, sometimes called a panic PIN, is a second code that looks like a normal unlock but quietly does something else: wipes the device, hides certain data or alerts someone. The person watching sees what looks like an ordinary unlock.
Some Android-based systems, such as GrapheneOS, offer a duress PIN that wipes the whole device. iOS doesn’t. On iPhone, anything like this has to come from an individual app, and it can only act on that app’s own data.
02 / BUILT INTO IOS
What iPhone offers instead.
Require the passcode instead of Face ID. Press and hold the side button and either volume button for about two seconds until the sliders appear, then tap Cancel. Your iPhone now needs the passcode for the next unlock, so it can’t be opened by holding it up to your face. Keep holding and the Emergency SOS countdown can call emergency services. Apple lists when Face ID requires the passcode.
Erase Data after 10 failed attempts. In Settings → Face ID & Passcode, turn on Erase Data. After 10 wrong passcode attempts in a row, the iPhone erases all content and settings. This isn’t a code you can enter on purpose, and a curious child can trigger it too. Only turn it on if you have a current backup. Apple explains passcode limits.
Stolen Device Protection. Adds Face ID or Touch ID checks, and a delay, before someone who knows your passcode can change your Apple Account or security settings away from familiar locations. It’s designed for theft. It doesn’t stop someone with your passcode looking through your photos.
Locked Hidden album and locked apps. Both open with Face ID, Touch ID or the device passcode. They keep things out of casual view, but anyone who knows or is given your passcode can open them. See how to hide photos on iPhone.
Every built-in lock ends at the device passcode. If you’re made to unlock the phone, iOS has nothing that shows a different version of it.
03 / BEFORE YOU RELY ON ONE
A delete code isn’t a safety plan.
- Deletion can make things worse. If someone controlling or hurting you notices files disappear, it may raise the risk to you. A plan made with a specialist service is safer than a single setting. In the US, the National Domestic Violence Hotline is on 1-800-799-7233; in the UK, the National Domestic Abuse Helpline is on 0808 2000 247.
- It can have legal consequences. Deleting data during a border inspection, a police investigation or under a court order may be treated as destroying evidence or obstruction. Know the rules where you are.
- Deletion isn’t forensic erasure. Removing files through an app doesn’t guarantee they can’t be recovered with specialist tools.
- You may lose things you meant to keep. Anything without a separate backup is gone.
Often, a separate space that simply doesn’t open for the wrong credential is enough, with no deletion at all.
04 / HOW VAULT DOES IT
Vault’s optional duress mode.
Vault can hold several independent vaults, each opened with its own pattern plus Face ID, Touch ID or your passcode. A pattern that doesn’t match any vault shows an empty screen and changes nothing. You might keep an everyday decoy vault with files you’d be comfortable showing, and others for everything else.
Duress mode is a separate, destructive option that’s off unless you arm it:
- Open the vault you’d be willing to show. This is the one that will be kept.
- Tap Settings → Set up duress mode, read the warning and tap Arm duress mode. Nothing is deleted yet, and only one vault can be armed at a time.
- The next time that vault is opened with its pattern, Vault deletes every other vault on this iPhone without warning, then opens the kept vault as normal. It works once, then switches itself off.


Opening a vault with its recovery words doesn’t trigger duress mode. To cancel, turn it off in Settings while the vault is still open, before you lock it.
What survives: Photos and other apps, your original files, anything you exported and encrypted backups saved outside the iPhone. Recovery words alone can’t bring back a deleted vault; you’d need a backup made beforehand. Vault’s independent security review is still pending. Read the security architecture and limits before relying on it.
STEP BY STEP
Set it up carefully.
Make and verify a backup of every vault you’d want to keep, then follow the duress guide.
Read the duress mode guide05 / QUESTIONS
Frequently asked questions.
No. iOS supports one device passcode, and there is no second code that wipes, hides or alerts when entered. The closest built-in options are quickly requiring the passcode instead of Face ID, and Erase Data after 10 failed passcode attempts.
No. iOS has no decoy or fake passcode that opens a different version of the phone. Some apps, including Vault, can use separate credentials inside the app to open different spaces.
Press and hold the side button and either volume button for about two seconds until the sliders appear, then tap Cancel. Your iPhone then requires the passcode for the next unlock. If you keep holding, the countdown can call emergency services.
No. It deletes the other Vault vaults on that iPhone. Photos, other apps, your originals, exports and encrypted backups saved elsewhere are not affected.
Only from an encrypted backup saved outside the iPhone before deletion, using that backup’s recovery words. Recovery words alone cannot bring back a vault whose files were deleted.