How To: Easily lock any app on your iPhone or iPad behind a passcode or biometric authentication

How To: Easily lock any app on your iPhone or iPad behind a passcode or biometric authentication

Some iOS and iPadOS apps give you the option to block them with Face ID, Touch ID, or a passcode, but there aren’t many.

Although iOS and iPadOS don’t have settings to lock any app with Face ID, Touch ID, or a passcode, some third-party developers enable this feature themselves. However, they are few and far between, but a few workarounds can help fill the gap.

Many argue that locking your iPhone or iPad should be enough to keep people from using your apps, but if you share a device, accidentally leave it unlocked for someone to look at, or don’t use a passcode on it, others people can open and use your apps. Apps like Messenger, Outlook, Signal, and WhatsApp let you block them with biometric authentication, but you’ll need to use shortcuts for other apps.

Apple takes no action to use biometric authentication or your password in a shortcut or automation, but there are other ways to increase the security of your apps. In the previous article, we showed AppDefense and AuthKit’s method of blocking apps in shortcuts, but it’s probably too complicated or intimidating for most users. Here are some simpler alternatives that don’t require additional shortcuts:

Method 1: Use Timer Automation

Usually, when you set a timer in the Clock app, the sound is muted when the timer ends. If the timer goes off while you’re using an iPhone or iPad, you’ll need to tap the notification to turn it off.

However, instead, you can set a timer to stop audio from playing on your iPhone or iPad. When the timer ends, your music, podcast, or other audio will stop and you will be taken to the lock screen. Moreover, you will still be taken to the lock screen even if no sound is playing. When you get to the lock screen, you need to re-authenticate with Face ID, Touch ID, or your passcode to continue. And that’s how we can use it as an app lock in shortcut automation.

To have your iPhone or iPad stop playing sound when the timer expires, open the Clock app, tap When Timer Ends for Timer, select Stop Playing, and tap Set.

Now, to use the timer as an app lock, go to the Automation tab in the Shortcuts app and start the new personal automation. Select “Application”from the list of triggers.

To set up a trigger, click “Select”and select the application or multiple applications that you want to block from external intruders. Then make sure the Open box is checked and click Next.

In the editor, click Add Action or the search bar, then find and select the Set Timer action. Set the new action field to “1”and change “minutes”to “seconds”. Then click Next.

Using the shortest possible time will make the automation work immediately, taking the person who opens the app to the lock screen. If you do this for a long time, that is how long they will have access to the application.

Finally, turn off the “Ask before launch”toggle and click “Don’t ask”when the confirmation message appears. Click Finish to finish.

Now the automation is set. When you or someone else tries to open the app you specified during the automation setup, your iPhone or iPad will automatically go to the lock screen and lock after one second. To use the app, close the lock screen, re-login with Face ID, Touch ID, or password, and you’ll be returned to the app.

Automation in action (left); The notification you receive when the timer is set to sound (right).

Caveats:

  • You will have to exit the lock screen and re-authenticate yourself every time you want to open the associated app.
  • When you need to time something, the timer is less useful as it won’t play a sound when it’s over. To get around this, you can play a sound during the timer and wait for it to stop, using that as an indicator.
  • Another workaround is to temporarily change “When the timer ends”to an actual sound effect. However, you must remember to change it back to “Stop Playing”when you’re done so that the app lock automation continues to work. If you don’t, your device will display a timer notification and play a ringtone or alert sound whenever the associated app is opened.
  • One second is still long enough for someone to see something in the app that they shouldn’t, but it depends on the app.
  • Anyone familiar with shortcuts can open this app and disable automation.

Method 2: Use the “Request Input”Shortcut

Although there is no authentication action in the shortcuts, you can create your own version using the “Request Input”action and the new home screen icon for the app.

Basically, you create a shortcut that asks for a passcode or password to open the app you want to protect. You then bookmark this shortcut to your home screen with the same app icon and name as the app itself. Hide the real app and the fake app will open the real app when authenticated, or do nothing if it’s a wrong passcode or password.

Open the Shortcuts app to start setting it up. Then add a new shortcut in the My Shortcuts (iOS and iPadOS 15) or Shortcuts (iOS and iPadOS 16) tab and name it like the app you want to block.

In the editor, click “Add Action”or the search bar, then find and select the “Request Input”action. In the new action field, click Text to see the available options.

  • Text: Set an alphanumeric password with or without special characters.
  • Number: Set a simple numeric passcode.
  • URL: Set a web address (real or fake) as the password.
  • Date: Set a specific day as the answer.
  • Time: Set a specific time as a response.
  • Date and Time: Set a specific time and date as the response.

Using text, a number, or a URL requires keyboard input when opening the app. Using the date or time options will open a picker where they can select a date, time, or date and time. I will use a number to set a simple password; To do the same, select Number.

Whatever you use, click “Hint”to enter text to explain what you expect from whoever opens the app to get in. I chose “Enter password”but it could be anything.

Now add an “If”action. You can find and select it from Add Action or the search bar, or it may already be available as a suggestion that you can click on at the bottom of the workflow. In the “If”action box, click “Condition”and select “yes”, then click “Number”and enter the passcode you want to use.

Then add an “Open Application”action and place it between the “If”and “Else”actions. Click “App”in the action box and select the app you want to block.

At the moment, the shortcut is already working. It will open the application of your choice if the password is correct and do nothing if not. However, if you want to make it more interesting, you can have the shortcut take a selfie every time a wrong answer is given, so you can know who tried to open the app.

Take a selfie if the password is incorrect (optional)

Add a “Take Photo”action and place it right after the “Otherwise”action. By default, the action will display the camera interface whenever an incorrect answer is given, so anyone who tried to open the app could take a picture, but that’s not what we want. Instead, tap the arrow icon to expand the submenu and turn off the Show Camera Preview option so that the shortcut takes a picture right away.

Then press “Back”and change it to “Front”to have the shortcut use the front camera to take selfies.

To see the selfie, add a Save to Photo Album action and place it below the Take Photo action. By default, it will save the selfie in the Recent album, but you can tap on it to change it to something else.

That’s all you need to take and save selfies. But you can also add a hint that tells the person they entered the wrong password.

Add “Incorrect”hint if password is incorrect (optional)

Add a Show Alert action below the Save to Photo Album action. Then replace “Do you want to continue?”with whatever prompt you want, such as “Invalid passcode, please try again.”

Add a shortcut to your home screen

To bookmark a shortcut on the Home screen in iOS and iPadOS 15, tap the options icon next to the shortcut’s name in the editor. On iOS and iPadOS 16, instead, click the arrow next to the name in the editor and click the Share icon. Then click “Add to Home Screen”.

You will see a preview of the icon and name of the shortcut, but the icon must be the icon of the app it opens. Tap the image below the home screen title and icon, then tap Select Photo or Select File to select an app icon.

If you don’t already have a saved icon for the app, you can install and use a shortcut like “Save Icons from the App Store “to get one. For this shortcut, you find the app in the App Store, click the share button, select the shortcut on the share sheet, click the share button, and then click Save Image. You can also set up a shortcut to automatically save an image of an application’s icon when it is selected on the share sheet.

With the image set as the icon of the app you want to block, click “Add”and the shortcut will appear on your home screen. Don’t forget to remove the real app from the home screen. It will still show up in the App Library, but someone trying to quickly open an app on someone else’s device might not have time to think about the App Library.

  • More Info: How to Hide Any App from the Home Screen of Your iPhone or iPad

Adding a shortcut to the home screen (left); Entering the correct password (in the middle); Entering the wrong password (right).

Now your label is ready. When someone opens a fake home screen app, it will ask for a password. If the password is correct, the application will open. Otherwise, it will take and save the selfie to an album in your Photos app, then prompt the user to try again.

Caveats:

Leave a Reply

Your email address will not be published. Required fields are marked *