Installing a .MSI File Using PowerShell in Windows 11/10
Have you ever downloaded a Windows application and found that its installer ends with the .msi extension instead of .exe? You can usually install it by double-clicking the file, but what if you want to install it through PowerShell?
Using PowerShell to install an MSI package is helpful when you’re troubleshooting an installation problem, managing software on your PC, or installing applications on multiple computers. You can also use command-line options to run an installation quietly, without displaying the usual setup wizard.
In this guide, you’ll learn what an MSI file is, how to install it using PowerShell, how to run an installation with administrator permissions, and how to troubleshoot common errors.
A .MSI File
An MSI file, short for Microsoft Installer package, is a type of Windows installation file. It contains information Windows Installer uses to install, configure, update, or remove an application.
For example, some desktop applications, drivers, and business software are distributed as MSI packages. When you open one, Windows typically launches an installation wizard that guides you through the process.
You can also install an MSI package through PowerShell by calling msiexec.exe, the Windows Installer command-line program. This gives you more control over the installation process, including whether the installer displays its interface and whether it creates a log file.
Before installing an MSI package, make sure you downloaded it from the software developer’s official website or another trusted source.
An MSI file can make system changes, install services, and add files to your computer, so you should verify its source before running it.
Installing a .MSI File Using PowerShell

To install an MSI file using PowerShell, open PowerShell as an administrator, navigate to the folder containing the MSI file, and run msiexec.exe /i “YourFile.msi”. Replace YourFile.msi with the actual filename. To install the package quietly, use msiexec.exe /i “YourFile.msi” /qn.
The easiest approach is to use the Windows Installer command through PowerShell.
Follow these steps carefully, especially if you’re new to command-line tools.
1: Download the MSI File
First, download the MSI package you want to install. Open your web browser and visit the application’s official website. Find the appropriate Windows download and save the MSI file to your computer.
For this example, let’s assume you downloaded a file named ExampleApp.msi and saved it in your Downloads folder.
Don’t worry if your actual filename is different. You’ll simply need to use the correct name in the commands later.
Once the download finishes, open File Explorer by pressing Windows + E. Select Downloads from the left sidebar and confirm that the MSI file is there.
Check the file extension and make sure you’re working with an .msi file rather than an archive or a different installer format. If Windows hides file extensions, enable View > Show > File name extensions in File Explorer on Windows 11. In Windows 10, open the View tab and select File name extensions.
Before continuing, verify that the file comes from a trusted source.
2: Open PowerShell as an Administrator
Some applications need administrator permissions to install files in protected folders, register system components, or create Windows services. Opening PowerShell as an administrator helps avoid permission-related errors when those privileges are required.
Click the Start button and type PowerShell in the search box.
Find Windows PowerShell or Terminal, depending on your Windows version and configuration. Right-click the application and select Run as administrator. If you open Windows Terminal, make sure its active tab is running PowerShell.
Windows may display a User Account Control prompt asking whether you want to allow the application to make changes to your device. Confirm only if you trust the application and intend to open an elevated session.
You should now have an administrator PowerShell window. Its title may include the word Administrator.
Keep this window open because you’ll enter the installation commands here.
3: Navigate to the Folder Containing the MSI File
PowerShell needs to know where your MSI package is stored. You can provide the full file path in your installation command, or navigate to the folder first.
If your file is in Downloads, enter this command:
Set-Location “$env:USERPROFILE\Downloads”
Press Enter to run it.
This command takes you to the Downloads folder of the Windows account you’re using. The $env:USERPROFILE variable represents your user profile directory, so you don’t need to type your Windows username manually.
Next, run:
Get-ChildItem *.msi
PowerShell will list MSI files in the current folder. Look for your downloaded package and confirm its exact filename.
If your MSI file is saved somewhere else, use the folder’s actual path instead. For example, you might enter Set-Location “C:\Installers” if the package is stored in a folder named Installers on your C drive.
4: Install the MSI File Using PowerShell
Now you’re ready to install the application.
If your file is named ExampleApp.msi and is located in the current folder, run:
msiexec.exe /i “ExampleApp.msi”
Press Enter to start the installation.
Here’s what the command means. msiexec.exe launches the Windows Installer program. The /i option tells Windows Installer to install the specified package. The quoted filename identifies the MSI file you want to install.
After running the command, the application’s installation wizard may appear. Follow its instructions, accept the license terms if you agree to them, and choose the required installation options.
Some installers may take a few minutes to finish. Wait for the process to complete before closing the installation window.
If the MSI file is stored in another folder, you can specify its full path instead:
msiexec.exe /i “C:\Installers\ExampleApp.msi”
Replace the example path and filename with your actual file location.
5: Install the MSI Package Without the Setup Wizard
Sometimes, you may want to install software without clicking through a setup wizard. This is known as a silent installation.
To run an MSI installation without displaying its normal user interface, use the /qn option:
msiexec.exe /i “ExampleApp.msi” /qn
The /qn option tells Windows Installer to display no installer interface. This can be useful for automated installations, but it also means you won’t see the usual progress window or prompts.
Before using this option, check the software developer’s documentation to confirm that the package supports unattended installation. Some applications require additional configuration or may need specific properties.
If you want to see a basic progress indicator instead, you can use:
msiexec.exe /i “ExampleApp.msi” /qb
The /qb option requests a basic user interface. The exact behavior may vary depending on the package.
For your first installation, using the standard command from Step 4 is usually easier because you can see any prompts or errors.
6: Create a Log File to Troubleshoot Installation Problems
If the installation fails, a Windows Installer log can help you identify what went wrong.
Run the following command:
msiexec.exe /i “ExampleApp.msi” /L*V “$env:TEMP\ExampleApp-Install.log”
This command requests a detailed installation log and saves it in your Windows temporary folder. The /L*V option enables extensive logging, which can help when investigating installation errors.
After the installation finishes, open File Explorer and enter %TEMP% in its address bar. Press Enter and look for ExampleApp-Install.log.
Open the log with Notepad and search for the word Return value 3. This entry can help you locate the section where an installation failure occurred, although you may need to read the surrounding lines to understand the actual cause.
Avoid sharing a complete installation log publicly without checking it first. Depending on the package, logs may contain usernames, file paths, or other environment details.
7: Check Whether the Installation Succeeded
After running the installation command, check whether the application was installed successfully.
If you used the normal interactive installer, look for a completion message. You can also open the Start menu and search for the application’s name.
Another option is to check Settings > Apps > Installed apps in Windows 11. In Windows 10, open Settings > Apps > Apps & features. Find the application in the list if it registers itself there.
If you used a silent installation, remember that the absence of a window doesn’t automatically mean the installation succeeded.
You can also capture the exit code immediately after the installer finishes:
$LASTEXITCODE
Run this command in the same PowerShell session. For Windows Installer, an exit code of 0 generally indicates success, while 3010 means the installation succeeded but a restart is required. Other codes may indicate that the installation failed or that another action is needed.
If the command returns a code indicating that a restart is required, save your work and restart Windows when appropriate.
MSI Installation Errors
If the MSI package doesn’t install, first double-check the filename and file path. A small typo or an incorrect folder can prevent Windows Installer from locating the package.
If PowerShell reports that the file can’t be found, run Get-ChildItem to check the current folder, or use the complete path in the command.
If you receive an access-denied error, confirm that PowerShell has the required permissions. However, administrator access won’t fix every installation issue, and some managed computers restrict software installation through organizational policies.
If Windows Installer reports that another installation is already in progress, wait for the existing installation to finish. Avoid terminating installer processes unless you understand the consequences.
If the package is incompatible with your version of Windows, download the correct edition from the software developer. You should also check whether the application requires a prerequisite, a particular processor architecture, or a previous version to be removed.
If the problem continues, review the log file from Step 6 and use the error details to narrow down the cause.
FAQs
1. Can I install an MSI file without opening PowerShell as an administrator?
Yes, if the application supports installation for the current user and doesn’t require elevated permissions. System-wide installations commonly require administrator approval.
2. What is the PowerShell command to install an MSI file silently?
Use msiexec.exe /i “ExampleApp.msi” /qn. Replace the filename with your actual package name. Check the developer’s instructions before running a silent installation.
3. Why does PowerShell say the MSI file cannot be found?
The command may point to the wrong folder or use an incorrect filename. Navigate to the correct directory or provide the complete path to the MSI file.
4. How can I uninstall an MSI-installed application using PowerShell?
If you know the product’s MSI product code, you can use msiexec.exe /x “{PRODUCT-CODE}”. Replace the placeholder with the actual product code. Save your work first, and avoid using guessed product codes.
5. Is installing an MSI file through PowerShell safe?
It can be safe when the package comes from a trusted source and you understand what it installs. Verify the publisher and avoid running unknown MSI files with administrator permissions.
Summary
Installing an MSI file using PowerShell is straightforward once you know the Windows Installer command. Open PowerShell with the required permissions, navigate to the package’s folder, and run msiexec.exe /i “YourFile.msi”.
You can use /qn for a silent installation, /qb for a basic interface, and /L*V to create a detailed log when troubleshooting errors.
Always replace the example filename with the actual package name, verify the download source, and check the installation result before assuming everything worked.
With these steps, you can install MSI packages more confidently on Windows 10 and Windows 11.
