Here is the scaffolding to create a WiX installer that uses a Burn bootstrapper that can support upgrading while allowing the user to change to a new installation directory.


Create an InstallFolder variable and populate it with what you want to be your default installation directory.

Pass your InstallFolder variable to your MSI package.


In your MSI package, store the installation directory in the registry so we can check it out during an upgrade.

During install, retrieve the previous installation directory; if it exists.

Finally, set the INSTALLFOLDER property to either the previous installation directory or the installation directory supplied by the bootstrapper.

The installer will behave as follows:

  • Clean install, no installation directory selected -> Default installation directory
  • Clean install, installation directory selected -> Selected installation directory
  • Upgrade, no installation directory selected -> Previous install directory
  • Upgrade, installation directory selected -> Selected installation directory

What’s also nice about this configuration is that you have access to PREVIOUSINSTALLFOLDER at anytime you could schedule a custom action. This allows you to do any migration to the new folder. This might include moving data files from the previous install folder to the new one.