When creating your reference image for Windows 10, you might want to remove the Universal Apps for various reasons. The community have come up with several scripts to accomplish this task, and don’t want to take any credit for coming up with the idea to do it with PowerShell. However, I wanted to share my version of a PowerShell script that removed the built-in apps in Windows 10.

In this script, I’ve taken another approach compared to those created by other community members. Since new versions of Windows 10 will emerge 2-3 times a year, I don’t want to update a script to support the new version that might incorporate new Universal Apps. Instead, I’m white-listing Universal Apps that I want to keep (like the Calculator), and remove everything else. In my experience, this should lead to the least amount of maintenance and that’s what I’m all about.

Script

As with the release of Windows 10 1607, a few more apps were added compared to Windows 10 version 1511. Edit the WhiteListedApps variable and make the changes that you seem fit in terms of which apps that should not be removed. As for Features on Demand, there’s also a white list of packages that won’t be removed when running the script. Edit the WhiteListOnDemand variable to fit your organizational requirements.

Update 2017-06-27: Script has been updated to only log output to RemovedApps.log file and not generate any errors that might cause MDT sequence to break.

Update 2017-03-23: Script updated with Write-LogEntry function to write to a log file called RemovedApps.log placed in C:\Windows\Temp. Applications like Quick Assist and Contact Support can now also be removed with this script. A bug has also been addressed causing the list of appx packages not to be fully populated.

# Functions
function Write-LogEntry {
    param(
        [parameter(Mandatory=$true, HelpMessage="Value added to the RemovedApps.log file.")]
        [ValidateNotNullOrEmpty()]
        [string]$Value,

        [parameter(Mandatory=$false, HelpMessage="Name of the log file that the entry will written to.")]
        [ValidateNotNullOrEmpty()]
        [string]$FileName = "RemovedApps.log"
    )
    # Determine log file location
    $LogFilePath = Join-Path -Path $env:windir -ChildPath "Temp\$($FileName)"

    # Add value to log file
    try {
        Add-Content -Value $Value -LiteralPath $LogFilePath -ErrorAction Stop
    }
    catch [System.Exception] {
        Write-Warning -Message "Unable to append log entry to RemovedApps.log file"
    }
}

# Get a list of all apps
Write-LogEntry -Value "Starting built-in AppxPackage and AppxProvisioningPackage removal process"
$AppArrayList = Get-AppxPackage -PackageTypeFilter Bundle -AllUsers | Select-Object -Property Name, PackageFullName | Sort-Object -Property Name

# White list of appx packages to keep installed
$WhiteListedApps = @(
    "Microsoft.DesktopAppInstaller", 
    "Microsoft.Messaging", 
    "Microsoft.StorePurchaseApp"
    "Microsoft.WindowsCalculator", 
    "Microsoft.WindowsCommunicationsApps", # Mail, Calendar etc
    "Microsoft.WindowsSoundRecorder", 
    "Microsoft.WindowsStore"
)

# Loop through the list of appx packages
foreach ($App in $AppArrayList) {
    # If application name not in appx package white list, remove AppxPackage and AppxProvisioningPackage
    if (($App.Name -in $WhiteListedApps)) {
        Write-LogEntry -Value "Skipping excluded application package: $($App.Name)"
    }
    else {
        # Gather package names
        $AppPackageFullName = Get-AppxPackage -Name $App.Name | Select-Object -ExpandProperty PackageFullName
        $AppProvisioningPackageName = Get-AppxProvisionedPackage -Online | Where-Object { $_.DisplayName -like $App.Name } | Select-Object -ExpandProperty PackageName

        # Attempt to remove AppxPackage
        if ($AppPackageFullName -ne $null) {
            try {
                Write-LogEntry -Value "Removing application package: $($App.Name)"
                Remove-AppxPackage -Package $AppPackageFullName -ErrorAction Stop | Out-Null
            }
            catch [System.Exception] {
                Write-LogEntry -Value "Removing AppxPackage failed: $($_.Exception.Message)"
            }
        }
        else {
            Write-LogEntry -Value "Unable to locate AppxPackage for app: $($App.Name)"
        }

        # Attempt to remove AppxProvisioningPackage
        if ($AppProvisioningPackageName -ne $null) {
            try {
                Write-LogEntry -Value "Removing application provisioning package: $($AppProvisioningPackageName)"
                Remove-AppxProvisionedPackage -PackageName $AppProvisioningPackageName -Online -ErrorAction Stop | Out-Null
            }
            catch [System.Exception] {
                Write-LogEntry -Value "Removing AppxProvisioningPackage failed: $($_.Exception.Message)"
            }
        }
        else {
            Write-LogEntry -Value "Unable to locate AppxProvisioningPackage for app: $($App.Name)"
        }
    }
}

# White list of Features On Demand V2 packages
Write-LogEntry -Value "Starting Features on Demand V2 removal process"
$WhiteListOnDemand = "NetFX3|Tools.Graphics.DirectX|Tools.DeveloperMode.Core|Language|Browser.InternetExplorer"

# Get Features On Demand that should be removed
$OnDemandFeatures = Get-WindowsCapability -Online | Where-Object { $_.Name -notmatch $WhiteListOnDemand -and $_.State -like "Installed"} | Select-Object -ExpandProperty Name

foreach ($Feature in $OnDemandFeatures) {
    try {
        Write-LogEntry -Value "Removing Feature on Demand V2 package: $($Feature)"
        Get-WindowsCapability -Online -ErrorAction Stop | Where-Object { $_.Name -like $Feature } | Remove-WindowsCapability -Online -ErrorAction Stop | Out-Null
    }
    catch [System.Exception] {
        Write-LogEntry -Value "Removing Feature on Demand V2 package failed: $($_.Exception.Message)"
    }
}

# Complete
Write-LogEntry -Value "Completed built-in AppxPackage and AppxProvisioningPackage removal process"

 

Using the script in MDT

1. Using this script is really no brainer, simply download it, call it Invoke-RemoveBuiltinApps.ps1 and place it in the %SCRIPTROOT% directory, meaning the <DeploymentShareRoot>\Scripts directory in MDT.
186_2
2. In your task sequence for Windows 10, add a Run PowerShell Script step and set the PowerShell Script field to:

%SCRIPTROOT%\Invoke-RemoveBuiltinApps.ps1

186_3_1
Start your reference image creation process and watch the magic happen!

Nickolaj Andersen
Principal Consultant and Enterprise Mobility MVP. Nickolaj has been in the IT industry for the past 10 years specializing in Enterprise Mobility and Security, Windows deployments and Automation. In 2015 Nickolaj was awarded as PowerShell Hero by the community for his script and tools contributions. Author of ConfigMgr Prerequisites Tool, ConfigMgr OSD FrontEnd, ConfigMgr WebService and a frequent speaker at user groups.

(16684)

comments
  • Eden Oliveira
    Posted at 21:25 March 17, 2016
    Eden Oliveira
    Reply
    Author

    Hi Nickolaj, Thank you for one more nice script.

    I have a question, I have already my Gold image built, I normally remove those apps using DISM offline, which takes some time to mount image, perform the actions, unmount, etc.
    So I was wondering, Can I use this script on my ConfigMgr 2012 Task Sequence?

    If so, how should I proceed?

    I believe I would need to create a package (no program) using this script, right?

    At which step should I add this script to on my TS?

    Thank you in advance.

    Eden

  • Dan Padgett
    Posted at 17:37 March 21, 2016
    Dan Padgett
    Reply
    Author

    just execute it as a TS step for run command line..

    %SystemRoot%\system32\WindowsPowerShell\v1.0\powershell.exe -executionpolicy bypass -file .\script.ps1

    make sure you specify a source for script

  • Jo Smith
    Posted at 16:05 May 25, 2016
    Jo Smith
    Reply
    Author

    I’ve been removing “windowscommunicationsapps”. Is that really an essential app? We don’t use Calendar, Mail, or Contacts/People, so I figured it wasn’t needed. I hope it doesn’t break anything.

    • CRoth2
      Posted at 10:56 March 13, 2017
      CRoth2
      Reply
      Author

      A reply to this would be helpful. It seems “essential app” term may be a more general statement than an actual requirement. I too am not using Mail, Contacts, People, or Messaging, so I don’t see why the “microsoft.communicationsapps” would be needed. I am thinking he needed it because he was keeping Messaging.

      Explanations as to why each is “needed” or “essential” would be helpful. And clarification as to whether “essential” means to the functioning of Windows or to the apps you have selected.

  • João Torres
    Posted at 19:10 May 31, 2016
    João Torres
    Reply
    Author

    Congratulations for your amazing script, however I have a doubt. How can I remove the apps for all users? Even if it’s a new user. Because when I deployed the captured image whit your script on the TS, I logged in for the first time on the VM with the captured image but the apps still there. I tried your script on the current user and it works like a charm, but when I change user, the apps still there for the new user.

    Best Regards.

  • Anders
    Posted at 12:11 June 22, 2016
    Anders
    Reply
    Author

    Hi
    i can’t get this to work. Deployment log returns: “TSHOST: Script completed with return code 0 TaskSequencePSHost 2016-06-21 16:07:59 0 (0x0000)
    ” it does not remove any app at all. In task sequense it runs before pre win update.

  • Petr Riha
    Posted at 13:47 July 2, 2016
    Petr Riha
    Reply
    Author

    Hi & let me say THX for incredible forum at the beginning. My issue is that I tried already several options how to remove Appx from Windows 10 x64, x86 Enterprise Edt. nevertheless all new users has installed apps like CandyCrash, XBox,.. :(. Can you give me an advice where this step should be exactly situated within SCCM Task Sequence to make it working please? The same issue I am dealing with setup StartMenu modification & language settings & I hope that with some advice I will be able to solve all. Thank you in advance.

  • Steve Whitcher
    Posted at 14:45 August 10, 2016
    Steve Whitcher
    Reply
    Author

    Thanks for updating this post. Do you happen to know what the each of the new built-in apps in v1607 do?

    I’m guessing DesktopAppInstaller is for the upcoming feature allowing win32 apps to be installed from the store, which is definitely one to keep.

    I thought that Messaging is the SMS app for mobile and for text messaging on a PC when paired with a windows mobile or android device. Do I have that wrong, or is there a reason that you consider this an essential app?

    What about StorePurchaseApp, which I see that you kept, and OneConnect, which you didn’t? Any idea what either of these do?

  • Steve
    Posted at 20:20 August 10, 2016
    Steve
    Reply
    Author

    Any way to get further information for each built-in application? Looking for specifically which each application is so we can make a meaningful decision to leave in or take out of the image.

    • Nickolaj
      Posted at 08:01 August 11, 2016
      Nickolaj
      Reply
      Author

      Unfortunately, I’m not aware of any such documentation. Would also like to have that information.

  • Sam
    Posted at 22:51 October 4, 2016
    Sam
    Reply
    Author

    Does this script work offline?

    I got this to work online (during the state restore phase) but will not work during the post-install phase.

  • John
    Posted at 12:09 December 23, 2016
    John
    Reply
    Author

    Would this also work in Windows 8.1 for removing the build-in Metro apps? If no would it be possible for you to make it compatible with Windows 8.1 too?

    Would be much appreciated!

    Best regards!

  • STRiCT
    Posted at 21:43 February 10, 2017
    STRiCT
    Reply
    Author

    This script was working great for us, but after a few updates it seems to be less effective. Not sure what is going on, so I am thinking it would be handy to have some sort of log output.

    I am hoping you can either modify your script to output a log, or maybe provide some direction on doing so our selves?

  • BaardH
    Posted at 16:57 February 15, 2017
    BaardH
    Reply
    Author

    Have you experienced any problems when language packs are applied?
    Whenever i add any kind of removal script, the translation of the computers settings get’s messed up.

  • AppLearner
    Posted at 16:32 February 23, 2017
    AppLearner
    Reply
    Author

    Thank you so much for this post worked perfectly for us. Deployed this in SCCM a little different than posted.

    1. Create folder in our apps share and placed the PS script there.
    2. Create a Package, make sure you select “Do Not Create a Program”.
    3. Add a Task – “Run PowerShell Script”, Point to package, Script name, PowerShell execution Policy to “Bypass”.

    • Nickolaj
      Posted at 13:12 March 2, 2017
      Nickolaj
      Reply
      Author

      Thanks for sharing how you implemented it!

      Regards,
      Nickolaj

  • Futureshock
    Posted at 23:21 February 25, 2017
    Futureshock
    Reply
    Author

    Is this script intended to be added for the capture task sequence or for the deploy? Thanks

    • Nickolaj
      Posted at 13:11 March 2, 2017
      Nickolaj
      Reply
      Author

      You can add it where you think it fits in your environment. I’m mostly using it when capturing images.

      Regards,
      Nickolaj

      • Futureshock
        Posted at 13:44 March 2, 2017
        Futureshock
        Reply
        Author

        Ok so that’s what is confusing me. So by adding it into the capture task you are then preventing it to come again at the deploy task? Or you are actually adding it at both tasks to play safe?

        On the other hand, I have been using the script for deploy (added at the same phase level as you (so within custom tasks and before Enable Bitlocker) but it doesn’t work for me. My monitoring console does mark the deploy as 100% completed but in my test VM it stucks at the big blue screen “just wait a little bit more / configuring app”. I have to reboot it to get access to the deployed VM and when I check all built-in apps are still there.

        Any hints or ideas?
        Thank you !!

  • Andrew
    Posted at 23:13 March 17, 2017
    Andrew
    Reply
    Author

    Is this suppose to remove all Apps except the exception ones?
    I am still left with Microsoft.WindowsAlarms, Microsoft.People, Microsoft.Office.OneNote and more on 1607.

  • Jordan Bardwell
    Posted at 15:28 March 28, 2017
    Jordan Bardwell
    Reply
    Author

    Hello,

    The script works, but throws back some errors at the end of an MDT task sequence.

    The majority of the errors are “Object not set…” and there will be about 20 of these in a row. Is there a way to silence these errors?

    Thanks,

    Jordan

  • Markus
    Posted at 08:23 March 30, 2017
    Markus
    Reply
    Author

    Hi Nickolaj,

    thank you very much for providing your script.
    i tried it out in my environment and I don’t know why, but it does not remove any apps on my systems.
    I run the script as administrator and the log file is filled with removing application package – messages but when I run

    PS C:\WINDOWS\system32> Get-AppxPackage -PackageTypeFilter Bundle -AllUsers | Select-Object -Property Name, PackageFullName | Sort-Object -Property Name

    i see the following list of Apps, and the apps are still present in start menu:

    Name PackageFullName
    —- —————
    Microsoft.3DBuilder Microsoft.3DBuilder_12.0.3131.0_neutral_~_8wekyb3d8bbwe
    Microsoft.BingWeather Microsoft.BingWeather_4.18.52.0_neutral_~_8wekyb3d8bbwe
    Microsoft.DesktopAppInstaller Microsoft.DesktopAppInstaller_1.2.2002.0_neutral_~_8wekyb3d8bbwe
    Microsoft.Getstarted Microsoft.Getstarted_4.5.6.0_neutral_~_8wekyb3d8bbwe
    Microsoft.Messaging Microsoft.Messaging_2.7.1001.0_neutral_~_8wekyb3d8bbwe
    Microsoft.MicrosoftOfficeHub Microsoft.MicrosoftOfficeHub_2017.318.204.0_neutral_~_8wekyb3d8bbwe
    Microsoft.MicrosoftSolitaireCollection Microsoft.MicrosoftSolitaireCollection_3.15.3072.0_neutral_~_8wekyb3d8bbwe
    Microsoft.MicrosoftStickyNotes Microsoft.MicrosoftStickyNotes_1.7.1.0_neutral_~_8wekyb3d8bbwe
    Microsoft.Office.OneNote Microsoft.Office.OneNote_2015.7967.57661.0_neutral_~_8wekyb3d8bbwe
    Microsoft.OneConnect Microsoft.OneConnect_1.1607.6.0_neutral_~_8wekyb3d8bbwe
    Microsoft.People Microsoft.People_2017.212.1701.0_neutral_~_8wekyb3d8bbwe
    Microsoft.SkypeApp Microsoft.SkypeApp_11.12.112.0_neutral_~_kzf8qxf38zg5c
    Microsoft.StorePurchaseApp Microsoft.StorePurchaseApp_11608.1000.24314.0_neutral_~_8wekyb3d8bbwe
    Microsoft.Windows.Photos Microsoft.Windows.Photos_2017.214.10010.0_neutral_~_8wekyb3d8bbwe
    Microsoft.WindowsAlarms Microsoft.WindowsAlarms_2017.301.1832.0_neutral_~_8wekyb3d8bbwe
    Microsoft.WindowsCalculator Microsoft.WindowsCalculator_2017.301.1149.0_neutral_~_8wekyb3d8bbwe
    Microsoft.WindowsCamera Microsoft.WindowsCamera_2017.125.40.0_neutral_~_8wekyb3d8bbwe
    microsoft.windowscommunicationsapps microsoft.windowscommunicationsapps_2015.8021.42017.0_neutral_~_8wekyb3d8bbwe
    Microsoft.WindowsFeedbackHub Microsoft.WindowsFeedbackHub_1.1702.653.0_neutral_~_8wekyb3d8bbwe
    Microsoft.WindowsMaps Microsoft.WindowsMaps_2017.317.1503.0_neutral_~_8wekyb3d8bbwe
    Microsoft.WindowsSoundRecorder Microsoft.WindowsSoundRecorder_2017.301.1209.0_neutral_~_8wekyb3d8bbwe
    Microsoft.WindowsStore Microsoft.WindowsStore_11701.1001.794.0_neutral_~_8wekyb3d8bbwe
    Microsoft.XboxApp Microsoft.XboxApp_2017.317.244.0_neutral_~_8wekyb3d8bbwe
    Microsoft.XboxIdentityProvider Microsoft.XboxIdentityProvider_2016.719.1035.0_neutral_~_8wekyb3d8bbwe
    Microsoft.ZuneMusic Microsoft.ZuneMusic_2019.17022.10301.0_neutral_~_8wekyb3d8bbwe
    Microsoft.ZuneVideo Microsoft.ZuneVideo_2019.17022.10311.0_neutral_~_8wekyb3d8bbwe

    Do you have any hints?

    Thanks,
    Markus

    • Nickolaj Andersen
      Posted at 08:40 March 30, 2017
      Nickolaj Andersen
      Reply
      Author

      Hi Markus,

      I ran the updated scripts on a couple of lab Windows 10 1607 machines and the apps were removed, even without a reboot. Could you provide some more information that might be helpful regarding your environment?

      Regards,
      Nickolaj

  • Adam Mancini
    Posted at 05:18 March 31, 2017
    Adam Mancini
    Reply
    Author

    Hi Nickolaj,

    Great script. It has shown me how to remove Apps that I was previously stumped on because appear as “WindowsCapabilities”.

    Unfortunately I believe the script is causing my sysprep to fail at the end of my build and capture:

    SYSPRP Failed to remove staged package Windows.ContactSupport_10.0.14393.0_neutral_neutral_cw5n1h2txyewy:0x80070002.

    SYSPRP Failed to remove apps for the current user: 0x80070002.

    Have you encountered this type of problem?

  • skatterbrainz
    Posted at 05:00 April 2, 2017
    skatterbrainz
    Reply
    Author

    This is increditastical! One question, why define the array $WhiteListedApps internally rather than using a separate file and Get-Content ?

    • Nickolaj Andersen
      Posted at 17:52 April 2, 2017
      Nickolaj Andersen
      Reply
      Author

      I’m not keen on using text files when it can be simplified directly in the script 🙂

  • David
    Posted at 20:26 April 4, 2017
    David
    Reply
    Author

    Very helpful script!

    On my Win10 1607 systems there are multiple flavors of many apps. For example:

    Microsoft.SkypeApp_11.12.112.0_neutral_~_kzf8qxf38zg5c
    Microsoft.SkypeApp_11.12.112.0_x64__kzf8qxf38zg5c
    Microsoft.SkypeApp_11.12.112.0_neutral_split.scale-100_kzf8qxf38zg5c

    I am curious as to why you used ‘-PackageTypeFilter Bundle’ as opposed to ‘Main, Framework’ (the default) or even ‘Main, Framework, Resource, Bundle’ and supplying a longer filter list?

    Specifying the entire filter list eliminates all variations of each app.

    Thank you,

    David

    • Nickolaj Andersen
      Posted at 10:57 May 5, 2017
      Nickolaj Andersen
      Reply
      Author

      Hi David,

      No particular reason, you can customize it exactly how you want. There’s no script that fits all possible scenarios. Great comment though, I should have made a note of that in the post.

      Regards,
      Nickolaj

  • Gattancha
    Posted at 09:18 April 5, 2017
    Gattancha
    Reply
    Author

    Just ran this via ConfigMgr on a Win10 1607 install.
    Worked a treat!

  • Kevin
    Posted at 19:54 April 7, 2017
    Kevin
    Reply
    Author

    Hi,

    How to Exclude the StickyNotes, windows 10 Photo viewer . this are the usefull apps and getting removed.

  • Kevin
    Posted at 19:58 April 7, 2017
    Kevin
    Reply
    Author

    I would like disable windows Store , Any help ? Also when I’m trying to open the some apps on windows 10, like Edge it saying ” Microsoft Edge can’t be Opened using Built-in administartor account,Sign in with a different accunt and try” ..what exaclty it means , DO i need set up UAC control using GPO for this issue ?

  • Pete Mitchell
    Posted at 02:24 April 11, 2017
    Pete Mitchell
    Reply
    Author

    Why bother? Any apps you remove for all users will just get reinstalled during the next Windows 10 update – ie 1607 -> 1703.

    • Nickolaj Andersen
      Posted at 07:00 April 11, 2017
      Nickolaj Andersen
      Reply
      Author

      Hi Pete, you can run the script during the post processing step in your In-Place Upgrade task sequence so that the apps are still removed. And once RS3 hits the market, you won’t have to do that anymore.

      Regards,
      Nickolaj

  • LLN
    Posted at 14:03 April 19, 2017
    LLN
    Reply
    Author

    This works great, except for one thing I ran into – it removes (?)/disables Internet Explorer. Is there a way to add that to the White List, if so, how? Thank you!

    • Andreas Björklund
      Posted at 15:07 April 19, 2017
      Andreas Björklund
      Reply
      Author

      Sure. Just add Browser.InternetExplorer to the $WhiteListOnDemand variable and you are good to go 🙂

      Example:
      $WhiteListOnDemand = “NetFX3|Tools.Graphics.DirectX|Tools.DeveloperMode.Core|Language|Browser.InternetExplorer”

      • LLN
        Posted at 19:34 April 19, 2017
        LLN
        Reply
        Author

        Thanks!

      • Jason
        Posted at 15:43 July 19, 2017
        Jason
        Reply
        Author

        Unfortunately I already ran this script and deployed to users, with Internet Explorer being removed :(. Our clients are impatient and want everything done yesterday. Is there a way to deploy internet explorer back to the users?

        • Jason
          Posted at 21:55 July 19, 2017
          Jason
          Reply
          Author

          I ran the slightly older script that kills off internet explorer 11

  • Julian Rodriguez
    Posted at 19:13 April 25, 2017
    Julian Rodriguez
    Reply
    Author

    I tried this by adding to my Windows 10 1703 reference image. After I deploy the reference image, the first user that logs on (with a new profile) has dead tiles (“e.g. P~microsoft…”). They go away after a reboot, but is there any way to prevent that from happening in the first place?

    • Jannis Jacobsen
      Posted at 08:54 May 2, 2017
      Jannis Jacobsen
      Reply
      Author

      We have the same issue here

      • Jonathan
        Posted at 21:45 May 2, 2017
        Jonathan
        Reply
        Author

        Deploy a custom start menu..?

    • Greg
      Posted at 10:28 May 5, 2017
      Greg
      Reply
      Author

      Same here, did you find a fix? I have tried numerous ways of modifying the DefaultLayouts.xml file and I can get the dead tiles from showing but then it defaults to showing Settings, Store and Edge. I just want a blank area with no tiles

    • Nickolaj Andersen
      Posted at 12:41 May 5, 2017
      Nickolaj Andersen
      Reply
      Author

      Hi Julian,

      I’ve seen this as well, but I’ve not been able to figure out a solution yet.

      Regards,
      Nickolaj

  • Greg
    Posted at 19:42 May 1, 2017
    Greg
    Reply
    Author

    I was using your script with 1607 with great success but am having problems in 1703. In MDT we have added IE11 but the script removes it. The log file shows: “Starting Features on Demand V2 Removal and then removes Browser.InternetExplorer~~~~0.0.11.0. I’ve tried to white lists it in the script but still have the issue.

    • Klaas-Wim van Diermen
      Posted at 15:07 May 8, 2017
      Klaas-Wim van Diermen
      Reply
      Author

      For Windows 10 1703 I uses this line:

      $WhiteListOnDemand = “NetFX3|Tools.Graphics.DirectX|Tools.DeveloperMode.Core|Language|Browser.InternetExplorer|Media.WindowsMediaPlayer”

      After Windows 10 1703 installation was finished Internet Explorer and Windows Media Player are still present.

      • Andy
        Posted at 17:00 July 14, 2017
        Andy
        Reply
        Author

        I used this to fix the IE missing issue but for some reason it still moved Media Player for me, any ideas?

  • John
    Posted at 13:25 May 8, 2017
    John
    Reply
    Author

    Hi there, great script but it remove MS Paint and IE 11. How can we white list this?

    • Klaas-Wim van Diermen
      Posted at 15:31 May 8, 2017
      Klaas-Wim van Diermen
      Reply
      Author

      $WhiteListedApps = @(
      “Microsoft.MSPaint”

      $WhiteListOnDemand = “NetFX3|Tools.Graphics.DirectX|Tools.DeveloperMode.Core|Language|Browser.InternetExplorer|Media.WindowsMediaPlayer”

      • John
        Posted at 15:23 May 11, 2017
        John
        Reply
        Author

        That’s very useful. How would you remove Mixed Reality Portal? I can uninstall it but it still appears on the start menu

        • Andreas Björklund
          Posted at 21:59 May 11, 2017
          Andreas Björklund
          Reply
          Author

          That mixed reality things is nice, but not always. Really annoying piece of software when you really don’t need it. So I went a little mad and did the following things:

          I ran a SQLite-browser as SYSTEM. Lookup the right row (ID: 3201 for me in build 16188) in the “Package” table, change the IsInbox to 0 on the row for the “Microsoft.Windows.HolographicFirstRun”-package in the “StateRepository-Machine.srd” file. You’ll find the file in C:\ProgramData\Microsoft\Windows\AppRepository .

          After that it was no problem running the command in PowerShell:
          Get-AppxPackage -Name ‘Microsoft.Windows.HolographicFirstRun’ | Remove-AppxPackage

          Don’t know the impact it will have on the system, if any. My system is still running fine 🙂

  • Mark
    Posted at 22:25 May 15, 2017
    Mark
    Reply
    Author

    Very nice script and I particularly like the white list idea as it makes for a straight forward way to customise the script. I have been testing this on the latest Windows 10 x64 Education v1703 wim as suggested this script is called during the State Restore of the reference build and everything appears to as expected.

    # White list of appx packages to keep installed
    $WhiteListedApps = @(
    “Microsoft.MicrosoftStickyNotes”,
    “Microsoft.MSPaint”,
    “Microsoft.Windows.Photos”
    “Microsoft.WindowsCalculator”,
    “Microsoft.WindowsStore”
    )

    $WhiteListOnDemand = “NetFX3|Tools.Graphics.DirectX|Tools.DeveloperMode.Core|Language|Browser.InternetExplorer|Media.WindowsMediaPlayer”

    Unfortunately the sysprep and capture fails and the C:\windows\system32\sysprep\panther\setupact.log identifies the Package Windows .ContactSupport_10.0.15063.0_neutral_neutral_cw5n1h2txyewy as the error.

    I have implemented the Windows Store Update as documented here, http://deploymentresearch.com/Research/Post/615/Fixing-why-Sysprep-fails-in-Windows-10-due-to-Windows-Store-updates

    Your script log shows that the features App.Support.ContactSupport~~~~0.0.1.0 & App.Support.QuickAssist~~~~0.0.1.0 have been removed and this is maybe true as there is no option to uninstall from the Apps & Features GUI.

    I am unable to remove the application using the PowerShell, Remove-AppxPackage Windows .ContactSupport_10.0.15063.0_neutral_neutral_cw5n1h2txyewy as it claims this app is part of Windows and cannot be uninstalled on a per-user basis. An Administrator can attempt to remove the app from the computer using Turn Windows Features on or off.

    Just hoping you could offer an insight and possible workaround so that full automation can be achieved.

  • Mister.Teche
    Posted at 17:20 May 16, 2017
    Mister.Teche
    Reply
    Author

    @ Mark. This is a known issue when removing apps pre-sysprep. I run this script in MDT/SCCM after the OS is deployed in a task sequence. Hope this helps

  • mark
    Posted at 13:02 May 18, 2017
    mark
    Reply
    Author

    Hey,

    Awesome script!! I was wondering how to make this apply to all new profiles created? This seems to only work on the profile deployed on, which for me is the admin account.

    Thanks,
    Mark.D

  • LLN
    Posted at 18:41 May 22, 2017
    LLN
    Reply
    Author

    Hello, how to whitelist all under Windows Accessories folder? Some of these apps are still present if you search for them, however, the script knocks them off of the default list.

  • Jamie Dickson
    Posted at 18:45 May 31, 2017
    Jamie Dickson
    Reply
    Author

    I used your script as instructed in MDT for Win 1607 and my Deployment Summary has a list of “Object reference not set to an instance of an object”. When I look at the log I see no errors. It did work as expected but would like to eliminate the errors.

    • John Hall
      Posted at 16:25 June 8, 2017
      John Hall
      Reply
      Author

      I am also getting these errors; three in all.

  • Rob
    Posted at 00:12 June 14, 2017
    Rob
    Reply
    Author

    also receiving Object not set errors but works great otherwise. Would love to hear how to eliminate those errors altogether so MDT doesn’t report errors everytime

    • J4FX
      Posted at 14:48 June 19, 2017
      J4FX
      Reply
      Author

      Would it be better to remove those apps in post install phase? Or is there a reason why you are doing it while full os is already running?

  • Phil
    Posted at 16:09 June 20, 2017
    Phil
    Reply
    Author

    I cannot get this to work for all profiles on either 1607 or 1703 they are removed for the admin account but any other user profile just has a bunch of broken apps listed under Other

  • Nickolaj Andersen
    Posted at 10:02 June 27, 2017
    Nickolaj Andersen
    Reply
    Author

    Script has now been updated to address some of the issues reported in the comments.

    /Nickolaj

  • Jeremy
    Posted at 18:33 June 28, 2017
    Jeremy
    Reply
    Author

    I’m having to use SCCM as opposed to MDT for deployment and I have added this setup in a similar fashion as you have it here in your example images, yet still the bloat remains. Any considerations there that I may take to get this working?

  • Leave a Reply to Nickolaj Andersen
    Cancel Reply