Skip to content

Instantly share code, notes, and snippets.

@saif71
Created October 30, 2021 08:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save saif71/9ee8af34388f468b9fe69f91442d81da to your computer and use it in GitHub Desktop.
Save saif71/9ee8af34388f468b9fe69f91442d81da to your computer and use it in GitHub Desktop.
UWP App Removal
# Remove Windows UWP Apps
# github/icedterminal
# v1.0.1
# ==============================================================================================================
# DOWNLOADING THIS SCRIPT:
# While this script is clearly safe, Windows may block this file. You will need to unblock it if that's the case.
# Additionally, PowerShell blocks scripts for safety. Run the command: set-executionpolicy unrestricted
# You can revert this change with the command: set-executionpolicy restricted
#
# COPYING AND PASTING THIS SCRIPT:
# Copy and paste into an empty notepad window. Save it as "what_ever_you_want_to_name_it.ps1".
# This will bypass the need to change execution policy and unblock files.
# Right click this file and select "Run with PowerShell"
#
# ABOUT
# This script will remove apps and de-provision them so they no longer appear with newly created users.
# You can no longer reinstall these default apps when you run the command to do so.
# Read over the list of apps and fill in the package name on line 28 in the format: photos|maps|camera
# Check for admin
if (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator")) { Start-Process powershell.exe "-NoProfile -ExecutionPolicy Bypass -File `"$PSCommandPath`"" -Verb RunAs; exit }
Write-Host "Please wait while a system restore point is created."
Checkpoint-Computer -Description "Remove Apps Script"
Write-Host "Press any key to continue"
Read-Host
$BloatApps = "app|names|here"
$RemoveApps = Get-AppxPackage -allusers | where-object {$_.name -match $BloatApps}
$RemovePrApps = Get-AppxProvisionedPackage -online | where-object {$_.displayname -match $BloatApps}
ForEach ($RemovedApp in $RemoveApps) {
Write-Host Removing $RemovedApp.name
Remove-AppxPackage -package $RemovedApp -erroraction silentlycontinue
}
ForEach ($RemovedPrApp in $RemovePrApps) {
Write-Host Removing provisioned $RemovedPrApp.displayname
Remove-AppxProvisionedPackage -online -packagename $RemovedPrApp.packagename -erroraction silentlycontinue
}
Write-Host "Removal complete"
Start-Sleep 3
exit

Manually remove apps

3D Viewer

This does not remove Paint 3D.

get-appxpackage -allusers *3d* | remove-appxpackage -verbose

Alarms and Clock

You do not need this app for the additional time zones clocks. However, this does offer more than the Windows shell limitation of two extra.

get-appxpackage -allusers *alarms* | remove-appxpackage -verbose

Camera

Do not remove if you have a webcam.

get-appxpackage -allusers *camera* | remove-appxpackage -verbose

Feedback

I encourage you leave this installed as you can report bugs.

get-appxpackage -allusers *feedback* | remove-appxpackage -verbose

Get Started

This 99% useless.

get-appxpackage -allusers *getstarted* | remove-appxpackage -verbose

Help

The inernet is significantly more helpful than this app.

get-appxpackage -allusers *help* | remove-appxpackage -verbose

Mail and Calendar

If prefer this over web-based email in your browser, or want to use Calendar, then leave it installed. Outlook, Thunderbird and even Mail on macOS are generally regarded as the better apps.

get-appxpackage -allusers *windowscommunicationsapps* | remove-appxpackage -verbose

Maps

This map app uses Bing Maps.

get-appxpackage -allusers *maps* | remove-appxpackage -verbose

Messaging

On desktop, this version is restricted to SMS messages sent via Skype. You may add your SMS carrier at an additional charge found on your monthly bill. If you want SMS messsages on desktop, consider Your Phone.

get-appxpackage -allusers *messaging* | remove-appxpackage -verbose

Mixed Reality

If you do not have VR, this app is not needed.

get-appxpackage -allusers *mixedreality* | remove-appxpackage -verbose

My Office hub

Your Office apps are untouched.

get-appxpackage -allusers *officehub* | remove-appxpackage -verbose

Note apps

note will remove both apps. Otherwise, specify.

get-appxpackage -allusers *note* | remove-appxpackage -verbose
get-appxpackage -allusers *OneNote* | remove-appxpackage -verbose
get-appxpackage -allusers *stickynotes* | remove-appxpackage -verbose

Paint 3D

This does not remove Win32 based Paint that everyone likes. If you have Surface computer/device, it is worth keeping installed.

get-appxpackage -allusers *paint* | remove-appxpackage -verbose

People

If you use Mail and Calendar, you'll want this.

get-appxpackage -allusers *people* | remove-appxpackage -verbose

Photos

If you prefer something else, remove it. Otherwise, leave this installed.

get-appxpackage -allusers *photos* | remove-appxpackage -verbose

Skype

If you don't use it, remove it.

get-appxpackage -allusers *skype* | remove-appxpackage -verbose

Solitaire

This version is really a step back. Loaded with ads requires you to be online.

get-appxpackage -allusers *solitaire* | remove-appxpackage -verbose

Sound (Voice) Recorder

If you use something else, remove it.

get-appxpackage -allusers *soundrecorder* | remove-appxpackage -verbose

Wallet

This appears to be missing on newer builds. Nothing may uninstall if the package is absent.

get-appxpackage -allusers *wallet* | remove-appxpackage -verbose

Weather

The Weather Channel app was superior to this, but TWC has stopped development and removed it.

get-appxpackage -allusers *weather* | remove-appxpackage -verbose

XBOX apps

If you specify just xbox, you remove everything except Game Mode! The Identity Provider Service gets removed too! This means you can no longer login to UWP games like Forza. Those titles utilise Xbox Play Anywhere and need it.

I encourage you to leave at least one of the core apps. The Xbox app (GamingApp) or Console Companion (xboxapp). If you don't have one of them you will lose access to game invites, messages, and various notifications.

get-appxpackage -allusers *xboxapp* | remove-appxpackage -verbose
get-appxpackage -allusers *GamingApp* | remove-appxpackage -verbose

The commands below remove only the Game Bar. Disable it from the Settings first, then run these.

get-appxpackage -allusers *tcui* | remove-appxpackage -verbose
get-appxpackage -allusers *xboxgameoverlay* | remove-appxpackage -verbose
get-appxpackage -allusers *xboxgamingoverlay* | remove-appxpackage -verbose
get-appxpackage -allusers *xboxspeechtotextoverlay* | remove-appxpackage -verbose

Your Phone

App to send and recieve messages with your linked phone. Requires Your Phone app to be installed on your Android phone. Android only. iOS is unsupported.^[Your Phone app requirements and set up: https://support.microsoft.com/en-us/topic/your-phone-app-requirements-and-set-up-cd2a1ee7-75a7-66a6-9d4e-bf22e735f9e3]

get-appxpackage -allusers *yourphone* | remove-appxpackage -verbose

Zune Video and Music

To remove Zune Video and Music, use zune. Otherwise, specify.

get-appxpackage -allusers *zune* | remove-appxpackage -verbose
get-appxpackage -allusers *zunemusic* | remove-appxpackage -verbose
get-appxpackage -allusers *zunevideo* | remove-appxpackage -verbose
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment