Skip to Content
Sindre Sorhus
Back to Actions

Updated

How to Encrypt Text in Shortcuts on iPhone and Mac

By Sindre Sorhus, who makes the Actions app

With Actions

  1. Install Actions, and open it once.
  2. In your shortcut, add the “Encrypt Text” action of Actions.
  3. Put the text in the action, and type a key of exactly 32 English letters and digits, like a random password.
  4. Run the shortcut. The result is the encrypted text, which you can save in a file or send.
  5. To decrypt, make a shortcut with the same action, choose “Decrypt” in place of “Encrypt”, and give it the encrypted text and the same key.

The action uses AES-256-GCM, and works on the device: nothing leaves it. The encrypted text is Base64 text, so you can paste it anywhere. Without the key, nobody can read it, also not you, so keep the key safe.

Tips

  • Do not put the key in a shortcut that you share. Read it from a file on your device, like with the “Get File from Folder” action.
  • To encrypt a photo or another file, use the “Encrypt File” action of Actions.

Get Actions

Additional actions for the Shortcuts app

Download on the App Store

Free

Requires
macOS, iOS, or visionOS 26 or later
Updated
June 2026
US App Store rating
4.8/5 (703 ratings)

More about Actions

Without an app

The Shortcuts app can change text to Base64 with the “Base64 Encode” action, but that is not encryption: anyone can decode it.

To keep a text private without a shortcut, put it in a locked note in the Notes app.