What is Gatekeeper?
Gatekeeper is a built-in security feature in macOS designed to prevent you from installing malicious software. By default, it only allows you to install apps downloaded directly from the official Mac App Store or apps created by “identified developers” (developers who pay Apple for a cryptographic signing certificate).
If you try to install a piece of open-source software, an older game, or a small indie app that isn’t signed by Apple, Gatekeeper will block the installation and throw an error stating the app “cannot be opened because it is from an unidentified developer.” In the past, you could bypass this with a simple “Anywhere” toggle in System Preferences, but Apple hid that option. You can restore it using the Terminal.
How to Restore the “Anywhere” Option in macOS
To disable Gatekeeper’s strict enforcement, you must disable the spctl assessment subsystem.
- Open your Mac’s Terminal application (found in Applications > Utilities, or by searching via Spotlight).
- Copy and paste the following command exactly as written:
sudo spctl --master-disable
- Press Enter.
- The Terminal will prompt you for your Mac login password. Type it in (the characters will remain invisible as you type for security) and press Enter again.
Verify the Change:
To confirm Gatekeeper is disabled, click the Apple Logo > System Settings (or System Preferences) > Privacy & Security. Scroll down to the “Security” section. Under the heading “Allow applications downloaded from,” you will now see a third option titled Anywhere, and it will be selected.
You can now install any application, from any developer, without macOS blocking the launch.
To reverse this change and turn Gatekeeper back on, open Terminal and run: sudo spctl --master-enable