I wrote a script before on how to remove builtin apps in Windows 10 that was based on Ben Hunter’s script to do the same https://ccmexec.com/2015/08/removing-built-in-apps-from-windows-10-using-powershell/
As always, make sure you uninstall what you really need some apps can be reinstalled from the Store some are harder or impossible to get back.
Not everything we can/want to remove are Apps, some of the Apps are installed as “Capabilities” instead and can be removed with PowerShell as well. Quickassist is a Windows Capability for instance. To list all Windows capabilities on a Windows 10 Computer runt he following PowerShell command.
“Get-WindowsCapability -Online”
With each new version of Windows 10 there are new apps that can/should be removed from a Windows 10 enterprise client. I have re-written the script so it reads the Capabilities to remove from one text-file and the apps to uninstall from another text file. These text files needs to have the Windows 10 build-number in the file name so that we can use the same Task Sequence step for multiple Windows 10 versions without have to create modify the script itself as shown below.
The script can be downloaded from here: https://github.com/Ccmexec/MEMCM-OSD-Scripts
In the Task Sequence we can now have one step that runs the Powershell script and the script will uninstall different apps based on the Windows 10 Build number it is running on like shown below.
The script will also create a log file in C:\Windows\temp with the name RemoveApps_Buildnr as shown below. It could have been placed in the SMSTSLOG folder as well but thought it is better placed in C:\Windows\Temp.
When a new version of Windows 10 is released we simply do the following:
- Deploy a Windows 10 with the new build without removing any apps.
- Run the following Powershell command:
$Appx = Get-AppxPackage | select name
$appx | Out-File -FilePath C:\temp\Appx.txt - Then we take the Appx.txt file and remove all the apps from the list that should NOT be removed, so the list only contains apps that we want to remove.
- Save the file in the Package Source folder with the name Apps17999 where “17999” is the buildnumber.
- Then we copy one of the Capabilities files so there is a Capabilities17999 file as well.
- Update the package on the DP’s and test the script.
That gives us a more flexible and simple way to handle the removal of builtin apps.
I hope it is useful!
Excuse my ignorance but what/where are the capabilities file(s)?
Thanks
Hi,
thanks for the feedback! I will update the blog post on Capabilities.
Regards,
Jörgen
Always nice to read another post. Will you make some about your current task sequence and what each step does, for instance the ‘EdgeWelcome’ step?
Hi
Yes I will try to write a post in that.
Regards,
jörgen
I would also love to see which steps do what during OSD. This looks very different from our TS that we use to deploy clients.
Hi Jörgen, great work as always. 2 brief questions:
1) Do you have a better site than Microsofts list of Win10 apps (https://docs.microsoft.com/en-us/windows/application-management/apps-in-windows-10) explaining each component/app (and ideally with comments on whats safe to remove and what isn’t)
2) Removed apps returning has been an issue on previous builds, any comment on the need to add regkeys as explained in this article in your script to ensure the removed apps stay removed? https://docs.microsoft.com/en-us/windows/application-management/remove-provisioned-apps-during-update
Have a look at my post in the comments here: https://ccmexec.com/2019/04/updated-removeapps-script-for-windows-10-1903/
I have made updated the script to implement the Microsoft workaround to prevent apps reappearing on pre-1803 versions of Windows 10.
If you can’t find the script, I have also copied it here: https://gist.github.com/wizzkidd/dae414d721560d3fec8b1c652436709c
Great job Jörgen Nilsson
Hi Jörgen, I find your task sequence very, very, interesting. I mean, I can tell there is a huge difference between yours and the default TS from MDT. I recently started to add more tasks into my task sequence to order to do more automatic configuration. But, as I read more of your blogs, I can see there are a lot of good ideas in your TS. Will you mind to share? or doing a blog about them? Thanks!
one important thing:
if you install PCs like that, and a domain user logs into his new win10 PC for the first time, he get’s the win10 default start menu layout. There will be empty icons pointing to nowhere, if you remove the apps? Like the email app. The link will be visible, it won’t even be called “mail” but some random string like windows.app.4249fhehcudfhdfvd.file . How to avoid this without setting up a static startmenu?
Hi,
The best way to solve your scenario is to import a custom start-layout that is used per default for the user and in that case the end-user can change it as well.
Regards,
Jörgen
Mr. Jörgen Nilsson, this is AWESOME !!!.
this method not only works, it resolved the many challenges I was facing with others scripts. So thank you and keep the excellent work.
PS: I had implemented a lot of your post to our environment and they all works 🙂
Is it possible to ‘comment’ out what apps we want to keep in the txt files rather than delete them? The idea being able to keep track of what we decided to include.
Hi,
Not in the current state but I will keep it in mind when updating it.
Regards,
JÖrgen
Running 1803 and Mixed Reality Portal will not uninstall. Microsoft.MixedReality.Portal is not listed as an app in Get-AppxPackage. Wondering if anyone else is having trouble getting rid of Mixed Reality Portal?
Thank you so much for your work on this. This is extremely helpful.
One minor comment is that in your download files, Capabilites17763.txt lists App.Support.ContactSupport as a capability to remove. I wasn’t seeing App.Support.ContactSupport in the list returned by GetWindowsCapability on an 1809 machine without capabilities removed yet. According to https://docs.microsoft.com/en-us/windows/application-management/apps-in-windows-10, it looks like App.Support.ContactSupport changed to the provisioned app GetHelp starting in 1709. So, I don’t think App.Support.ContactSupport should be in the Capbilities.txt files from 1709 on.
Hi Jorgen,
Thanks for this article. I was trying to run the script after installing Windows 10 1809 (not adding in TS) and it gives me the below error.
Remove builtin apps based on Microsoft.Wallet Microsoft.Messaging Microsoft.MixedReality.Portal Microsoft.StorePurchaseApp microsoft.windowscommunicationsapps Microsoft.GetHelp Microsoft.WindowsMaps Microsoft.Office.OneNote Microsoft.XboxApp Microsoft.ZuneMusic Microsoft.YourPhone Microsoft.OneConnect Microsoft.WindowsAlarms Microsoft.People Microsoft.MicrosoftOfficeHub Microsoft.WindowsFeedbackHub Microsoft.SkypeApp Microsoft.Microsoft3DViewer Microsoft.WindowsCamera Microsoft.MicrosoftSolitaireCollection Microsoft.BingWeather
Unable to find package: Microsoft.Wallet
Removing Provisioned Package: Microsoft.Wallet_2.2.18179.0_neutral_~_8wekyb3d8bbwe
Path :
Online : True
RestartNeeded : False
Unable to find package: Microsoft.Messaging
Removing Provisioned Package: Microsoft.Messaging_2018.727.1430.0_neutral_~_8wekyb3d8bbwe
Path :
Online : True
RestartNeeded : False
This is for all of them. I checked the Apps are there but not removed. Is it something which needs to be run only from TS?
Hi,
It should still work depending on the permissions you run it with.. The package it is removing is for the current user and the provisioned package for all new users. So it will most likely not work as fully expected. and it looks like it is doing some parts in your post above.
/Jörgen
works well,
if i log in as a user, i still have 2 placeholders in the taskbar for “Mail” and the store, these are invisible, but physically there, i cant remove them; how to deal with that ?
Has anyone noticed that scripts to remove AppX seem to have stopped working in Windows 10 1809 from version 17763.253 (I have tested 17763.253, 17763.292 and 17763.316?
My own script (similar to this one) and also the script used in this article are failing fairly randomly for me when any LCU’s are applied from January 2019 onwards. Same script works on all other Windows 10 version I have tried (including 17763.195 which works just fine).
Hi,
yes seeing the same, getting it reported from everywhere, haven’t had time to investigate it though but reports tell me that running it as early as possible in the TS works much better..
I will investigate it as well..
Regards,
Jörgen
I was having the same issue with fast (SSD) machines. I found applying the April cumulative update and associated other updates made it work. This solution seems to be stable now. My TS now has the following in order:
Setup Windows and Configuration Manager
%systemroot%\System32\wusa.exe windows10.0-kb4480056-x64_03a6d426797796ba712e4dbd05b56fd9cbfc2e24.msu /quiet /norestart
%systemroot%\System32\wusa.exe windows10.0-kb4486553-x64_0c3111b07c3e2a33d66fed4a66c67dec989950a0.msu /quiet /norestart
%systemroot%\System32\wusa.exe windows10.0-kb4493509-x64_ec069505eddfb9175e376b7eea773182d06033f0.msu /quiet /norestart
%systemroot%\System32\wusa.exe windows10.0-kb4493510-x64_f692d391a4869d910c754895169dbd0d237a86da.msu /quiet /norestart
Restart Computer
Windows 10 App Removal Script
Hi
I have the same issue, have you found any solution?
The problem seems to affect DELL computers only.
Same problem, don’t find a reason
I moved the Remove AppX almost right after applying OS image. So far I’ve not had any issues. However I see other things that does not work as they did with 1709, i,e: OneVinn OSDBackground. My build is: 17763.316
HI,
Have you updated OSDBackground to the latest version?
Regards,
Jörgen
Hi Jörgen, I am in the process of updating it right now. I was using a older version which probably explains the error.
Thanks for this awesome script, however I’m stuck on how to implement it in my task sequence. I noticed that you created a package called “Windows 10 Remove Apps”. How do I configure the package? Do you specify the powershell script in the package? Do you have a step by step guide on what you did so that I can mimic it exactly? Thank you.
I figured it out. You just need to create a package without a program and point to where your source files are on the server. Then in the task sequence you point to the package, and the name of the script…that’s it.
This script as well as other scripts to remove default Windows 10 1809 apps still doesn’t seem to be working. Has anybody gotten any script to work recently?
Jörgen
I am building a ref image using MDT and windows 10 1809
The script runs but after the first login a user has icons that have a down arrow and they seem to come back.
the real problems are
network speed test
the office lens
Microsoft News
sway.
any ideas?
Hi,
Yes when removing apps, you must deploy a custom start menu as well otherwise you will see these missing icons, that is solved in 1903 though.
Regards,
Jörgen
Hey guys, if you would like this script to work with the new Windows 10 “20H2” release then you need to copy and paste the most recent text files and rename them 19042
Thanks Jörgen! This is still working perfectly with W11 23H2 build 22631. Appreciate all you do for the community!