Skip to content

“Installation Ended Prematurely Because of an Error” In Windows 10 – Fixed 2021

When you install or reinstall a program on Windows, the setup may stop with a fatal error, say that the installation failed, or show “Installation ended prematurely because of an error”. Most of the time, something left behind by a previous uninstall is causing it.

When programs are uninstalled, they leave files behind. If the uninstall was not complete, the next installation can fail with this error.

“Installation ended prematurely because of an error” is a generic Windows Installer error. It can happen with any software installation or reinstallation, so the fixes below also work for similar installation errors. This tutorial applies to computers, laptops, desktops and tablets running Windows 10, Windows 8 and Windows 7.

Update (October 2026): Windows 10 support ended on October 14, 2025, and Windows 7 and 8 are no longer supported either. The commands below also work on Windows 11.

In this article
  1. Fix 1: Re-register Windows Installer
  2. Fix 2: Re-register VBScript
  3. Step 3: Restart your PC and try again
  4. Still not working? Try these

Fix 1: Re-register Windows Installer

  1. Right-click the Start button and select Windows PowerShell (Admin) (on Windows 11: Terminal (Admin)).
  2. Run these two commands, one after the other. Press Enter after each line:
msiexec /unreg
msiexec /regserver

These commands usually don’t show any message, and that is normal.

Fix 2: Re-register VBScript

Many installers use VBScript during setup. If its file is not registered correctly, the installation can stop with this error.

  1. Type cmd in the search box, right-click Command Prompt and select Run as administrator.
  2. Run this command:
regsvr32 vbscript.dll

You should see a message that DllRegisterServer in vbscript.dll succeeded.

Step 3: Restart your PC and try again

You have to restart the PC after running the commands. Then try to install the software again.

Still not working? Try these

  • Run the installer as administrator: right-click the setup file and select Run as administrator.
  • Check the Windows Installer service: press Windows + R, type services.msc and press Enter. Double-click Windows Installer. If the startup type is Disabled, set it to Manual and click OK.
  • Remove the leftovers of the old installation: on Windows 10, Microsoft’s Program Install and Uninstall troubleshooter can fix problems that block programs from being installed or removed. You can find it on Microsoft’s page Fix problems that block programs from being installed or removed.

Does a program fail to start after installing, with a missing DLL message? See how to fix the “VCRUNTIME140.dll is missing” error.

Written by

Daniel

Daniel is the creator of Tips 2 Fix. He has been publishing tech tutorials on YouTube since 2013, and his videos have been watched more than 21 million times. Every guide on this site comes with a video where he shows the fix step by step, from Windows 11 upgrades on unsupported PCs to everyday Windows, Mac and Android problems.

Leave a Reply

Your email address will not be published. Required fields are marked *


Support Me