iOS 17: How to Delete Verification Codes Automatically on iPhone

What to know

  • With the iOS 17 update, you can tidy up the Messages app using the automatic verification codes clean-up feature.
  • This feature clears away verification codes entered via your iPhone’s Autofill capability. However, remember that this feature won’t automatically remove any codes you enter manually.
  • To automatically delete verification codes from your iPhone, go to Settings > Passwords > Password Options > Verification Codes and turn on the Clean Up Automatically toggle. 
  • Deleted verification codes can be recovered from Messages > Recently Deleted or Mail > Bin

What is Verification Codes Clean Up in iOS 17?

Apple makes it easier for you to deal with one-time passwords and verification codes that you may constantly receive on your iPhone when logging into an app or website. The feature comes in the form of an automatic clean-up tool that can be used to remove verification codes that have already been used to authenticate on an app or service. 

The Verification Codes Clean Up tool is accessible inside iOS settings and can be used to delete messages that contain verification codes received on the Messages and Mail apps on your iPhone. Just like on the verification codes you receive via SMS, Autofill can also enter codes you receive from an email you get on the Mail app. 

The Clean Up Automatically tool will only work when you enter verification codes on apps using the iOS Autofill feature. If you manually enter a verification code by opening the Messages or Mail apps, iOS won’t automatically clear them from your device. Clearing up messages with verification codes will help declutter your inboxes on both apps, leaving them free for more important messages. 

Related: 8 Ways to Reinstall Safari on iPhone [2023]

How to automatically clean up verification codes on your iPhone

  • Requirements: iOS 17 update (check under Settings > General > Software Update).

To enable the automatic clean-up of verification codes, open the Settings app on your iPhone. 

Inside Settings, scroll down and select Passwords

You’ll now be asked to authenticate your identity using Face ID or Touch ID.

Once you do that, you’ll arrive at the Passwords screen. Here, tap on Password Options

On the next screen, turn on the Clean Up Automatically toggle under “Verification Codes”. 

This will allow iOS to automatically clean up the verification codes you receive on the Messages and Mail apps. 

What happens when you enable automatic clean-up for verification codes?

Once you enable the Clean Up Automatically toggle for Verification Codes, iOS will remove any message or mail you receive on the Messages or Mail app containing verification codes once you use them. As soon as a verification code is inserted using the Autofill option on your iPhone, iOS will automatically delete the message or email with this code straightaway. 

We tested this feature by signing into a service with a one-time password that we received via Messages. To make sure this code is automatically deleted, you need to insert it by tapping on the Autofill-suggested option on top of the keyboard interface. 

First-time users will see this prompt on their screen. So to make sure your verification codes are removed automatically, tap on Delete After Use. This prompt won’t appear for subsequent code inputs. 

When you enter a verification code from Messages or Mail apps using Autofill, iOS will instantly clear the message with the code from the respective app. In case you want to recover this code for some reason, you can go to the Recently Deleted section on Messages app or the Bin folder on Mail app. 

That’s all you need to know about cleaning up verification codes automatically on an iPhone. 


Posted by

Ambivalent, unprecedented, and on the run from everyone's idea of reality. A consonance of love for filter coffee, cold weather, Arsenal, AC/DC, and Sinatra.