An iOS device will lock its owner out if the wrong passcode is entered six times in a row. The user will see a message that says the device has been disabled.
Never fear: if you’ve forgotten the passcode for your iPhone, iPad, or iPod touch, or your device has been disabled, there are some steps you can follow to get back into your device.
Pick a way to erase your device Unless you made a backup before you forgot your passcode, there isn't a way to save your device's data. You'll need to erase your device, which deletes all of your data and settings. Choose a way to erase:
Erase your device with iTunes If you've synced your device with iTunes, you can restore your device.
5. When you reach the Set Up screen while restoring your iOS device, tap Restore from iTunes backup. 6. Select your device in iTunes. Look at the date and size of each backup and pick the most relevant one.
Erase your device with iCloud If you set up Find My iPhone on your iOS device or Mac, you can use iCloud to erase and restore it.
If your device isn't connected to a Wi-Fi or cellular network, you can't erase it with Find My iPhone.
Erase your device with recovery mode If you've never synced with iTunes or set up Find My iPhone in iCloud, you'll need to use recovery mode to restore your device. This will erase the device and its passcode.
3. When you see the option to Restore or Update, choose Restore. iTunes will download software for your device. If it takes more than 15 minutes, your device will exit recovery mode and you'll need to repeat steps 2 and 3.
Get more help If you can’t force restart or use recovery mode because of broken buttons, contact Apple Support.