Put the iPhone into Recovery Mode
Connect the iPhone to a Mac or PC
Open Finder on Mac or iTunes on Windows or older macOS
Select the iPhone when it appears
Choose Restore iPhone
Confirm the restore to erase the device
Wait for the erase and reinstall process to finish
Set up the iPhone again after it restarts
If Activation Lock appears, enter the Apple ID and password previously used on the device
If you forgot the Apple ID password, use Apple’s account recovery process
