Windows is a highly flexible operating system, but that flexibility introduces risks when installing apps from third-party developers. Although you can scan installer files for malware before installation, some risk remains. While you cannot turn Windows into a tightly controlled “walled garden” like an iPhone (or even a Mac), you can still restrict what gets installed. Here are several methods to prevent the installation of non–Microsoft Store apps on a Windows PC.
Understanding App Installation in Windows
Windows apps are typically installed in two ways:
- Microsoft Store Apps: Installed directly from the Store, these apps run in a sandboxed environment and must pass Microsoft’s security checks.
- Traditional Desktop Apps: Installed via executable (.exe) or installer packages (.msi), these apps can be downloaded from any website on the internet.
By default, Windows allows both types, but with administrative controls, this behavior can be changed.
1. Using App Recommendation Setting
Windows includes a built-in setting that controls how the system handles .exe installers. You can use this feature to block unnecessary applications from being installed. It also helps prevent accidental installations caused by unintentionally clicking an installer file.
- Press Windows Logo + I keys and open the Settings app.
- Navigate to “Apps” section and select “Advanced app settings” option.

- Look for “Choose where to get apps” and click the dropdown next to it.
- Change the option from “Anywhere” to “The Microsoft Store only (Recommended)”. You can also select “Anywhere, but let me know if there’s a comparable app in the Microsoft Store” or “Anywhere, but warn me before installing an app that’s not from the Microsoft Store” option if that best suits your needs.

Whenever you double-click on an app installer file downloaded from the web, Windows will instantly block it with a popup saying, “The app you’re trying to install isn’t a Microsoft-verified app” as shown below. Click the “Browse Microsoft Store” button to open Microsoft Store and find equivalent apps. Otherwise, you need to click the “Change app recommendation settings” link and change to “Anywhere” before proceeding with the installation.

Note: This only restricts app installation, not execution. If a non-Store app is already installed, it can still run.
2. Using Group Policy Editor
If you manage a family PC or an office network, Group Policy is the professional way to lock things down.
- Press Windows Logo + R keys to open the Run prompt.
- Type gpedit.msc in the box and press “OK” button.
- Navigate to the following location and double-click “Configure App Install Control”.
Computer Configuration > Administrative Templates > Windows Components > Windows Defender SmartScreen > Explorer

- Select “Enabled” and set it to “Allow apps from Store only”.

This prevents all users on the computer from attempting to run installers downloaded outside of Microsoft Store.
Note: You can also use the AppLocker feature in Local Group Policy Editor to block non-Microsoft Store apps. Go to Computer Configuration > Windows Settings > Security Settings > Application Control Policies > AppLocker location and create custom Executable Rules and Windows Installer Rules to allow only trusted system locations such as Windows and Program Files while preventing apps from running from user-writable locations like Downloads or AppData. Under Packaged App Rules, allow Microsoft Store apps, which effectively restricts users to Store apps while blocking most non-Store applications.

3. Using Standard User Account
Windows supports both administrator and standard user accounts. You can keep administrator access for yourself and assign standard accounts to other users. When a standard user attempts to install a non–Microsoft app, Windows displays a User Account Control (UAC) prompt requesting an administrator password. If they do not have the password, the installation is blocked, which prevents most accidental installs.
4. Using Windows S Mode
If you are setting up a new device or performing a clean installation, Windows 11 in S Mode is a suitable option. It allows only apps from the Microsoft Store and blocks .exe files from running if they come from the web. To check, go to “Settings > System > About > Windows info”. If it shows “Windows 11 in S mode”, the restriction is active. Otherwise, you would need to reinstall Windows to enable it.
Final Words
Though these methods are effective, they may not stop running apps directly from the .exe file without installation or apps that run from an external drive (like from a USB). Other than that, you can choose one of the methods depending on your needs:
- For elder users: Set Windows 11 to allow apps from “Microsoft Store only”. Basic tasks like email and web browsing are typically sufficient for elders.
- For children: Use a standard account combined with Microsoft Family Safety features.
- For office environments: Apply restrictions through Group Policy for centralized control.
If you are the sole user of the computer, maintaining safe browsing and download practices is often more practical than enforcing strict restrictions that may become inconvenient.





