What is the command line to silently install an MSI file?


Solution 1:

Standard Installer Command-Line Options

/quiet

Quiet display option.

The installer runs an installation without displaying a user interface.

Examples:

msiexec /package Application.msi /quiet
msiexec /uninstall Application.msi /quiet
msiexec /update msipatch.msp /quiet
msiexec /uninstall msipatch.msp /package Application.msi / quiet

Note The equivalent Windows Installer Command-Line Option is /qn.

msiexec

run this command to find more information about the installation options.

Solution 2:


UPDATE June 2018: Although the tool shown below is no longer available for download, I found it via Wayback machine. I assume it is OK and legal to link to it, seeing as the tool was freeware. Updated links below.

UPDATE: This tool from Wise is regrettably not downloadable anymore. I am not sure if it is OK to distribute it either. It seemed to be a free tool distributed as part of their main Wise Package Studio suite, but I don't think it is open source. I wish they would release it as an open source tool.

The Wise packaging products have been discontinued due to a number of legal issues.


You got some good answers here already, but I just want to add the "quick and easy" way : use the "command line builder tool" from Altiris (direct download).

UPDATE June 2018: http://www2.wise.com/filelib/WICLB.exe - broken link resurrected from Wayback machine. Seeing as the tool was freeware I assume that is legal. Please run the download by virustotal.com for safety.

I am very experienced with msiexec.exe, but the command lines are so long that it is easy to make mistakes. I prefer to generate the complex ones and eliminate that error source.

N.B: hope posting download links to tools is ok! I am not affiliated with Altiris in any way. It's a free tool, it's easy to use and it works. Here is a screenshot:

enter image description here