Command line options available to uninstall Internet Explorer


In this blog, I am sharing the commands available to uninstall Internet Explorer.

Examples covered in this blog are for:

  • Internet Explorer 9
  • Internet Explorer 10
  • Internet Explorer 11

Example for uninstalling Internet explorer 9

  • Log on to the computer by using an administrator account or an account that has administrative rights.
  • Close all Internet Explorer browser windows.
  • Click Start, type cmd in the Search box, and then click cmd under Programs.
  • Right click and select Run as administrator
  • Copy the following command:

FORFILES /P %WINDIR%\servicing\Packages /M Microsoft-Windows-InternetExplorer-*9.*.mum /c “cmd /c echo Uninstalling package @fname && start /w pkgmgr /up:@fname /norestart”

  • Paste the command into the Command Prompt window, and then press Enter.
  • Restart the computer.

Example for uninstalling Internet explorer 10

  • Log on to the computer by using an administrator account or an account that has administrative rights.
  • Close all Internet Explorer browser windows.
  • Click Start, type cmd in the Search box, and then click cmd under Programs.
  • Right click and select Run as administrator
  • Copy the following command:

FORFILES /P %WINDIR%\servicing\Packages /M Microsoft-Windows-InternetExplorer-*10.*.mum /c “cmd /c echo Uninstalling package @fname && start /w pkgmgr /up:@fname /norestart”

  • Paste the command into the Command Prompt window, and then press Enter.
  • Restart the computer.

Example for uninstalling Internet explorer 11

  • Log on to the computer by using an administrator account or an account that has administrative rights.
  • Close all Internet Explorer browser windows.
  • Click Start, type cmd in the Search box, and then click cmd under Programs.
  • Right click and select Run as administrator
  • Copy the following command:

FORFILES /P %WINDIR%\servicing\Packages /M Microsoft-Windows-InternetExplorer-*11.*.mum /c “cmd /c echo Uninstalling package @fname && start /w pkgmgr /up:@fname /norestart”

with /quiet switch

FORFILES /P %WINDIR%\servicing\Packages /M Microsoft-Windows-InternetExplorer-*11.*.mum /c “cmd /c echo Uninstalling package @fname && start /w pkgmgr /up:@fname /quite /norestart”

 

  • Paste the command into the Command Prompt window, and then press Enter.
  • Restart the computer.

MORE INFORMATION

Articles:

What to do if you can’t uninstall Internet Explorer 9

http://support.microsoft.com/kb/2579295

 

Manual Process:

Install or uninstall Internet Explorer

http://windows.microsoft.com/en-us/internet-explorer/install-ie#ie=ie-11

Comments (43)

  1. Abster says:
    1. Where are the ending quotes in each command?

    2. Since IE's such an integral part of Windows, what do these commands really do? Also, how are they different from unchecking IE in the Windows Features dialog?

  2. Paul says:

    I have tried this solution to uninstall IE9 on a Windows 7 Professional (SP1), and for each .mum file that is processed, I get an error 'Access Denied', even though I am logged on as an administrator. When I checked the security properties for the .mum files, I did not have full control permissions, and could not grant myself full control. How do I get past this? I need to remove IE9 so that I can install IE10 or IE11. They will not install as long as IE9 is in the system.

    1. Eric says:

      @Paul in order for this to work in command prompt you need to “Run as administrator…” then it will work.

  3. Vivian says:

    You need to open the Command prompt with Run as Administrator. Click on Start – cmd – Right click – Run as Administrator

  4. axelr says:

    @Vivian

    Thanks Vivian!

    I should have been more precise on my steps. Rectified the steps!

  5. Anand Bhagat says:

    This commmand line is working fine manually. But when i try to deploy it(batch file) through SCCM 2012, its getting fail. Could you please suggest me the reason?

  6. Ron says:

    tried multiple times to uninstall IE 10 using these instructions, but was unsuccessful each time. Command appeared to run as expected, but after restarting IE 10 still works.

  7. Jim says:

    Works fine when deployed via sccm to win 7 32 bit but fails on win 7 64 bit.  Anyone know the trick to uninstall via sccm to a win 7 64 bit OS?

  8. axelr says:

    @Anand Bhagat  and Jim  

    I will try to get us some answers, but it will make more sense to post this question to the SCCM communities.

  9. axelr says:

    @Ron    

    Make sure you are running the command from an Elevated command window!

    This command should be run with elevated privilege.

  10. Matt says:

    @AxelRMSFT, @Vivian: yes, sure. I did use an elevated prompt.

    On the first run it issued an 'access denied' error anyway. on subsequent usage of the command the error was not raised again. might be a dependency issue…

  11. axelr says:

    @Matt    

    Review your event logs and see if that gives you any clues.

  12. Bart says:

    @Jim

    I also experienced this failing when deployed with SCCM but working ok when ran manually. After digging around it appears to be an issue with 64-bit redirection.

    I have expanded command line to include C:Windowssysnative path to cmd.exe and found that now works when deployed via SCCM 2012 R2 to a Win7 SP1 Ent. client.

    While troubleshooting I also added a logging option but can possibly be removed.

    FORFILES /P %WINDIR%servicingPackages /M Microsoft-Windows-InternetExplorer-11..mum /c "C:Windowssysnativecmd.exe /c echo Uninstalling package @fname && start /w pkgmgr /up:@fname /quiet /norestart /l:C:tempIE11_uninstall

  13. Alaa says:

    Command worked and IE 9 seems to be gone. However, IE 8 is now running after PC restart. Maybe I just uninstalled the updated version. Can I use same script and change 9. to 8. ?

  14. axelr says:

    @Alaa: What OS Version are you running?

  15. Alaa says:

    @AxeIRMSFT

    It should be Vista SP2. The 8. worked according to cmd– two uninstalling started top and low as what happened with IE9. Yet after rebooting I have IE 9 again and this method does not work any more.

    cmd output :

    ———————————————————————————————————/

    Microsoft Windows [Version 6.0.6002]

    Copyright (c) 2006 Microsoft Corporation.  All rights reserved.

    C:Windowssystem32>FORFILES /P %WINDIR%servicingPackages /M Microsoft-Windows

    -InternetExplorer-9..mum /c "cmd /c echo Uninstalling package @fname && start

    /w pkgmgr /up:@fname /quiet /norestart

    ERROR: Files of type "Microsoft-Windows-InternetExplorer-9..mum" not found.

    C:Windowssystem32>

    —————————————————————————————————————–/

    I also have been getting this at start-up right after registry cleaning:

    "setting up personalized settings for rundll32 iedkcs32 dll. BrandE 4 Signup"

    Number of top rated anti malware programs does not recognized any thing wrong with IE.

    Now, do you know on any command line script that show which IE is currently running.

    Thanks,

  16. Evan says:

    ERROR: Files of type "Microsoft-Windows-InternetExplorer-9..mum" not found.

    I have this same issue running Win 7 SP1.

    Can not uninstall IE9 and thus can not install either IE 10 or 11

    Not listed in programs list of cpl, so can not use that method

    Suggest something else to manually kill off IE 9 so to install 10 or 11.

  17. Rreinstein says:

    Greetings! i ran the command to remove IE11 on my Windows Server 2012 R2 server, and oddly enough, I can no longer run VMs under Hyper-V. Could this be related?

    Thanks,

    Robert

  18. axelr says:

    @ All

    If the command is not working, I suspect there is more work that needs to be done to find out what is happening to the machine. I suspect some type of corruption. These scenarios are not easy to isolate. you can start by reviewing the CBS.log, but it requires a skillful person to interpret the entries and it is best to open a Support case.

  19. Iviikel says:

    The command removes IE9 from the systems I have tested on. But then when navigating through windows explorer (explorer.exe), everytime you click a folder to move into another directory, it opens the folder in a new instance of explorer. ex. drilling to C:windowssystem32 I'd end up with 3 explorer windows.

  20. axelr says:

    @Iviikel    

    You may want to reset your  Windows Explorer to default settings.

    Try this:

    To restore Windows Explorer to default settings, follow these steps:

    a- Open Windows Explorer, click on Tools menu > Folder Options.

    b- Click the View tab.

    c- Click on Restore defaults then click on Apply and OK.

  21. luc says:

    It worked fine for me :-) many thanks to provide this information

  22. Jack says:

    It Worked Perfectly for me, Thank you!

  23. Matthias says:

    Great it worked fine for me too, thanks for sharing this.

  24. Michael M says:

    I've noticed that after running this script I cannot reinstall IE 11 again.

    For SCCM deployment how can I make it not echo the steps.. I don't want the users to see anything?

    We're 95% Windows 7 32 bit with the remaining being W7 64 and W8.1 64.

  25. Parker Berry says:

    Recently, I've been hearing audio ads on my computer. I checked the application tab under task manager and saw one instance of I.E. 11 running which was showing an ad website which would change to another such site and so on and so on. What is disturbing is that I did not have I.E. open. I rarely use it. When I right click on the task and select "go to process" nothing happens. I am running windows 7 and normally I would think this is a virus. I ran AVG and S&D spybot and turned up negative results. however with MS Intrusively pushing win 10 ads via KB3035583. I'm beginning to think MS is responsible for this also. I had to completely uninstall IE 11 and that put a stop to it. Has anyone else had this problem or does anyone have an insight into this?

  26. пп says:

    FORFILES /P %WINDIR%servicingPackages /M Microsoft-Windows-InternetExplorer-*10.*.mum /c "C:Windowssysnativecmd.exe /c echo Uninstalling package @fname && start /w pkgmgr /up:@fname /quiet /norestart /l:C:tempIE10_uninstall

  27. Exley says:

    too bad IE 8 cannot be yanked out of win7 via that command

  28. satheshkumar says:

    how can i doing reduce the ie for 11 to 8

  29. axelr says:

    @satheshkumar    

    May we ask, why you would want to do that?

    We recommend you use IE11 with latest IE cumulative update.

    Latest IE11 Cumulative as of today is MS15-094

    technet.microsoft.com/…/ms15-094.aspx

  30. Eric says:

    FYI Guys – If you want to remove ALL if upgrades and go back to the default run this in an elevated command prompt:

    FORFILES /P %WINDIR%\servicing\Packages /M Microsoft-Windows-InternetExplorer-*.*.mum /c “cmd /c echo Uninstalling package @fname && start /w pkgmgr /up:@fname /quiet /norestart

    This will uninstall 9, 10 and 11.

    1. Eric says:

      Additionally do not forget to reboot, otherwise the changes wont take affect immediately.

  31. Phillip says:

    When I run this, I get error – syntax error, /c is not allowed more than one time

    1. Andrew says:

      Has the same issue, but I simply retyped the two quotation mark characters in the command and it worked. It appears that the quotes character on the site here is not the same as typing quotes in to the command prompt.

  32. allen says:

    I follow the instructions and get the error “Invalid Syntax. ‘/c’ option in not allowed more than ‘1’ times(s). Also, should there not be a closing ” somewhere in the command line? Please help, as my Internet Explorer just stopped working – it doesn’t even open and I cannot seem to remove it, so trying to re-install doesn’t work.

    1. AxelRMSFT says:

      @Allen
      Yeah, you can try using this:
      FORFILES /P %WINDIR%\servicing\Packages /M Microsoft-Windows-InternetExplorer-*11.*.mum /c “cmd /c echo Uninstalling package @fname && start /w pkgmgr /up:@fname /quiet /norestart”

      You can open Appwiz.cpl from Start\Run or elevated Command Window.
      Click on View Installed Updates
      Type Internet Explore 11 and removed it from here
      After removed, reboot and try to install it again using Windows Updates.

      1. Rene says:

        This worked for me after getting the same error as you did:
        FORFILES /P %WINDIR%\servicing\Packages /M Microsoft-Windows-InternetExplorer-*9.*.mum /c “cmd /c echo Uninstalling package @fname && start /w pkgmgr /up:@fname /norestart”

        https://support.microsoft.com/en-us/kb/2509039

    2. TeeC says:

      @allen
      @Phillip
      When you copy and paste quotes (“”) into command line form a website they often end up not copying correctly.
      You’re best to type the command in or copy and paste then delete the quote and retype the quotes.
      The closing quote comes after the /norestart

      @AxelRMSFT
      The syntax for your quiet mode is mistyped on your post. You’ve typed /quite. It should be /quiet.

    3. SomeGuy says:

      One thing no one has mentioned: the problem may be a need to re-type the quotation marks if you’re doing a direct copy-paste from this page. Apparently, some form of “smart quotes” may tag along, and what appear to be quotation marks in the CMD window aren’t treated as such. Paste it in, use the arrow keys to navigate to each quotation mark, delete it, and re-enter it. I did this after getting the same /c error, and it finally worked.

  33. P Sears says:

    I also get ERROR: Invalid syntax. ‘/c’ option is not allowed more than ‘1’ time(s). Type ‘FORFILES /?” for usage.

    1. P Sears says:

      Fixed by changing the two double quotes from ‘smart’ to ‘dumb’ quotes.

  34. Brent says:

    Tried this but there is no mum file in the location specified. Win7 SP1 which was at IE9. Attempted to install IE11 but got the Unable to complete message. Uninstalled IE9 update and tried again but got same answer. Now I am suck in limbo. IE is there but totally useless, Unable to access menus or buttons, Internet Options in Ctl Panel does not open, nothing is listed in Updates. IE opens with a bare screen (incomplete IE11 I think) and crashes instantly when you attempt to enter any address. A reinstall gives the message that a previous install is incomplete and will not continue. I’ve attempted installs in Safe mode, elevated privileges, local install and web download. Running out of ideas. Any further suggestions greatly appreciated.

    1. AxelRMSFT says:

      @Brent
      When you look at the IE11_Main.log under the c:\windows directory what errors do you see?