1. Vahty
  2. Guides

Pattern lock on iPhone: how it works, and is it safe?

An iPhone cannot be unlocked with a pattern the way an Android phone can. But an app can use one to protect what is inside it. Here is what that means and how safe it is.

Updated · By the Vahty team

The iPhone has no pattern lock of its own

On Android you can unlock the whole phone by joining dots. On an iPhone you cannot: the lock screen takes a passcode, Face ID or Touch ID, and Apple does not let apps change that.

What an app can do is use a pattern for itself. That is how pattern lock vault apps work. Your iPhone opens the usual way, and the vault inside asks for a pattern before it shows anything.

This is useful for one simple reason: the people most likely to look at your phone are people who already know your passcode. A partner, a child, a friend holding it for a minute. A separate lock with a separate secret keeps one part of the phone closed even to them.

Two very different kinds of pattern lock

Apps use a pattern in one of two ways, and from the outside they look the same.

A pattern as a curtain. The app shows a pattern screen, and behind it your files sit on the phone as ordinary, readable files. Connect the phone to a computer, or open the app’s folder with a file tool, and the photos are there. Many older vault apps work like this.

A pattern as the key. The app turns the pattern into an encryption key. Without the right pattern the files are scrambled data. This is how Vahty works, and it is the kind to look for.

A quick test: read the app’s own description. An app that really encrypts will name how (for example “AES-256”) and will warn you that a forgotten pattern cannot be reset without a recovery phrase. An app that can email you a reset link is not using your pattern as the key.

Pattern or PIN: the real numbers

How many different secrets are possible?

Lock Possible combinations
4-digit PIN 10,000
6-digit PIN 1,000,000
Pattern, 3 × 3 grid, four dots or more 389,112
Pattern, 4 × 4 grid, six dots or more 4,350,069,651,464 (about 4.35 trillion)

So a classic 3 × 3 pattern sits between a 4-digit and a 6-digit PIN. A 4 × 4 grid is a different league: about four million times more possibilities than a 6-digit PIN. (We counted these ourselves using the usual rule that a line cannot jump over an unused dot.)

Two honest caveats.

People do not choose at random. Most patterns start in a corner, and many are letters like L, Z or N. A guesser tries those first, just as they try 1234 and birthdays for a PIN. The numbers above are the ceiling, not what a lazy pattern gives you.

The count is not the whole story. What matters more is where and how fast someone can guess.

What really makes a pattern lock safe

Imagine a thief who can try a billion guesses a second on a powerful computer. Against that, even trillions of patterns do not last long. So a well-made vault is built so that guessing has to happen on the phone itself.

Three things do that:

  1. The key is tied to the phone. iPhones contain a chip called the Secure Enclave. If the vault’s key is tied to that chip, a copy of the vault will not open on another device.
  2. Each guess is slow. The pattern is passed through a deliberately heavy calculation before it becomes a key.
  3. Wrong guesses cost time. After a few misses, the app makes you wait, and the waits grow.

Vahty ties its key to the Secure Enclave and makes wrong guesses cost time. After 5 wrong patterns the waits are 30 seconds, 1 minute, 5 minutes, 30 minutes, then 1 hour per try. The pattern lock page and the security page have the details. Vahty is in final testing and not on the App Store yet.

How to draw a strong pattern

  • Use six dots or more. Length matters more than anything else.
  • Do not start in a corner, or at least not the top left one.
  • Change direction several times, and cross your own line if you can.
  • Avoid letters and simple shapes. L, Z, N, a square and a plain zigzag are the first things anyone tries.
  • Hide the line. If the app can hide the line as you draw, use that in public.
  • Wipe your screen now and then, so the smudge of your finger does not draw the pattern for you.
  • Write down the recovery words. A strong pattern you have forgotten is the most common way people lose a vault.

Pattern and Face ID together

Some people want Face ID for speed. In a vault, the safest arrangement is Face ID as well as the pattern rather than instead of it: the app asks for both. Then a sleeping owner’s face is not enough, and neither is a pattern someone watched you draw. Vahty offers Face ID this way, as an optional second lock. For the wider comparison, see pattern vs PIN vs Face ID.

In short

  • An iPhone’s lock screen cannot use a pattern; a vault app can.
  • Make sure the pattern is the encryption key, not a curtain.
  • A 4 × 4 pattern of six dots or more has far more combinations than a 6-digit PIN, and a vault whose key is tied to the Secure Enclave will not open from a copy on another device.
  • Draw something long and odd, and keep your recovery words on paper.

Questions

Can I put a pattern lock on my iPhone lock screen?

No. Apple only offers a passcode, Face ID and Touch ID for the lock screen, and apps are not allowed to replace it. A pattern can only lock the contents of a single app, such as a vault.

Is a pattern safer than a PIN?

It depends on the grid and the length. A 3 × 3 pattern has 389,112 possibilities, which is less than a 6-digit PIN (1,000,000). A 4 × 4 pattern of six dots or more has about 4.35 trillion, far more than any PIN people actually use.

Can someone see my pattern from the smudges on the screen?

Sometimes, on a clean screen used only for that. Use an app that can hide the line while you draw, pick a pattern that crosses itself or changes direction, and add Face ID as a second lock if the app offers it.

What is the best pattern lock app for iPhone?

Look for one where the pattern is the encryption key, not just a screen in front of ordinary files. Vahty and Vaultaire both work this way. Many older vault apps with a pattern option only hide files.

Hand your phone to anyone.

Vahty is a private vault for iPhone with no account and no server. It comes to the App Store soon.

Coming soon. One email on launch day.