If your iPhone asks for a passcode from an older device while you enable iCloud, it is usually asking you to approve access to end-to-end encrypted iCloud data, often for iCloud Passwords & Keychain or to resume syncing. Read the prompt carefully: enter the passcode for the device it names, or use another approval option shown on screen. This is a security check, not necessarily a request for your Apple Account password or the passcode for your current iPhone.
Identify what the prompt is asking for
Use the wording on the screen to distinguish the requested credential. A previous device’s passcode, your current iPhone’s passcode, your Apple Account password, and a two-factor authentication verification code are different things.
- If the prompt names an older device, it is asking for that device’s passcode. Your current iPhone’s passcode may not work if it is different.
- If it asks for your current passcode, enter the passcode for the iPhone you are using.
- If it asks for your Apple Account password or a verification code, use the credential specified by the prompt instead of a device passcode.
- If you are setting up or transferring to a new iPhone, an old-device passcode request may be part of the transfer process rather than an iCloud Keychain approval.
Some approval flows may ask for the current device passcode first and then the previous device’s passcode. Follow the sequence shown on your screen.
Why Apple asks for an older device passcode
iCloud Passwords & Keychain can sync passwords, passkeys, Wi-Fi information, and other account information across devices you approve. Apple uses approval and recovery checks to help protect access to this information. The old passcode may be requested when a device needs approval to access protected data.
The prompt can appear even if you are not deliberately turning on Keychain at that moment. It may come up while signing in to your Apple Account, finishing setup, enabling iCloud Passwords & Keychain, or resuming iCloud syncing. If you selected Approve Later during sign-in, Apple may ask you to approve later with an old passcode or another device.
Advanced Data Protection (ADP) is optional. It extends end-to-end encryption to additional iCloud categories, but it is not required for an old-passcode prompt to appear.
Check whether iCloud Passwords & Keychain is being set up
To check the relevant setting, open Settings > [your name] > iCloud. Under Saved to iCloud, tap Passwords. Depending on your iOS version or layout, you may need to tap See All first. On iOS 17 or earlier, the setting is labeled Passwords & Keychain.
If you want to use the feature, turn on Sync this iPhone and follow the approval steps presented. Apple says your Apple Account should have two-factor authentication enabled and recommends updating your devices before setting up iCloud Keychain. Setup may also request your current device passcode or Apple Account password; those requests are separate from an old-device approval unless the prompt says otherwise.
What to do if you do not have the old passcode
- Read the complete prompt. Confirm whether it names a previous device and check for options to approve with another device or use another recovery method.
- Use another trusted device if the iPhone offers it. Apple documents approval from another device for iCloud Keychain setup. Depending on the flow, an option such as an iCloud Security Code may also appear. Use only the choices shown for your account.
- If you see an iCloud Data Not Syncing alert, open Settings, tap the alert or badge, and follow the instructions. If the alert remains after you authenticate your account, Apple advises contacting Apple Support.
- Do not guess repeatedly. If you cannot remember the requested passcode, check the available approval and recovery options rather than entering guesses.
Recovery options can vary by account and situation. Options described for Managed Apple Accounts, such as some student accounts, should not be assumed to apply to personal Apple Accounts.
Think carefully before resetting encrypted data
If you cannot approve access, your iPhone may offer to reset or delete end-to-end encrypted data. This is not the same as simply turning iCloud off and back on. Depending on the flow, protected information may become unavailable or encrypted data may be removed.
Read the full confirmation screen before proceeding, because the affected data and steps can vary. If Advanced Data Protection is enabled, Apple says it does not have the encryption keys needed to recover the protected data. Recovery depends on the methods available for your account, which may include a device passcode or password, a recovery contact, or a recovery key.
Keep your passcode safe
- Enter a passcode only in the iPhone’s genuine setup or Settings prompt.
- Do not share your device passcode with another person.
- Do not enter it into a message, email, or third-party website.
- Before confirming any reset or deletion, review the exact warning displayed on your device.